Hi guys,
Is there a formula to draw a border around a range of cells depending on a cell value. So if C1 = 1 put a border around A1;B10 or if C1 = 2 put a border around A10;B20.
Thanks
Hi guys,
Is there a formula to draw a border around a range of cells depending on a cell value. So if C1 = 1 put a border around A1;B10 or if C1 = 2 put a border around A10;B20.
Thanks
You can do this with conditional formatting.
You would format the upper left corner (in your example, A1) to have a top and left border if C1=1. Similarly you would format:
B1--top and right
A10--left and bottom
B10--right and bottom
A2:A9--left
B2:B9--right
Use the same strategy for A10:B20 for C1=2.
(Excel does not let you apply conditional formatting to a range of cells for an outside border around the entire range, according to my experiments. When I select an outside border, it applies it to all cells in the range individually, which is not what you want.)
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks