Thanks Thanks:  0
Likes Likes:  0
Results 1 to 10 of 10

Thread: IF statements and font colour

  1. #1
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    this may seem like an odd question. Im trying to set up an IF statement using 2 sheets. Im am basically saying IF (cell A) is greater than (Cell B), then print (cell A) in a new cell, AND USE GREEN FONT.
    I can setup the IF statement no problem, but I dont know if there is a way to include putting the info in green font if it satisfies the IF statement. Any help would be much appreciated.
    thanks

  2. #2
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    See the Excel Help Index topic for "Apply conditional formats to cells".

  3. #3
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Ive looked through there, and I cant find anything that gives me a syntax for font attributes.

  4. #4
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    AHH...nevermind..found it...
    thanks!

  5. #5
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    duh..further to the above question.
    I have it setup like this:

    a1 a2
    if a2>a1...then print a2 in green font.

    figured that out.

    Now I cant figure out how to copy this conditional formula downwards through b1 b2, c1 c2 etc...it keeps copying the formula making reference to cell a1...Ive tried highlighting the whole range of cells to be formatted with the same conditions, but it will not allow me to do so....

    help!
    thx.

  6. #6
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-04-24 12:43, acura wrote:
    duh..further to the above question.
    I have it setup like this:

    a1 a2
    if a2>a1...then print a2 in green font.

    figured that out.

    Now I cant figure out how to copy this conditional formula downwards through b1 b2, c1 c2 etc...it keeps copying the formula making reference to cell a1...Ive tried highlighting the whole range of cells to be formatted with the same conditions, but it will not allow me to do so....

    help!
    thx.
    So you've applied a conditional format to cell A2? Copy A2 and Paste Special... Formats onto cell B2, C2, etc.

    ...Or, with cell A2 selected double-click the Format Painter toolbar button and the drag across B2, C2, etc.

  7. #7
    Board Regular Brian from Maui's Avatar
    Join Date
    Feb 2002
    Posts
    8,450
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Acura,

    If you're trying to anchor A1 use $A$1

    If you want to copy and paste using B1,C1, etc. click on the cell, copy, go to Edit/Paste Special/Format

  8. #8
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Ive tried both those methods..The problem that I seem to be getting, is even when I "paste special" the formats, to cells b2, c2 etc...it is still basing the conditional formula on the original cell A1.

    ie: if a2 > a1 print a2 in green font.
    when i paste special the format down to cell b2, it is still comparing b2 to a1...and not b1...I dont know why...ive tried paste special and format painter, with the same results.

  9. #9
    New Member
    Join Date
    Apr 2002
    Posts
    6
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    ok..im a moron.

    ive figured it out....when I used that conditional format wizard thing, and clicked to select the cell to base my conditions on...it automatically defaulted to $a$1...
    duh.

  10. #10
    MrExcel MVP Aladin Akyurek's Avatar
    Join Date
    Feb 2002
    Location
    The Hague, NL
    Posts
    84,060
    Post Thanks / Like
    Mentioned
    38 Post(s)
    Tagged
    8 Thread(s)

    Default

    On 2002-04-24 12:55, acura wrote:
    Ive tried both those methods..The problem that I seem to be getting, is even when I "paste special" the formats, to cells b2, c2 etc...it is still basing the conditional formula on the original cell A1.

    ie: if a2 > a1 print a2 in green font.
    when i paste special the format down to cell b2, it is still comparing b2 to a1...and not b1...I dont know why...ive tried paste special and format painter, with the same results.
    An easier method is to select the whole range of interest starting at A1 and use your formula:

    =A2>A1




Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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