+ Reply to Thread
Results 1 to 2 of 2

Cell border on cell value

  1. #1
    Forum Contributor
    Join Date
    03-18-2008
    Posts
    162

    Cell border on cell value

    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

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2502
    Posts
    27,023

    Re: Cell border on cell value

    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.)
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1