Consulting

Results 1 to 6 of 6

Thread: coping conditional format and moving the compare cell with it

  1. #1

    coping conditional format and moving the compare cell with it

    Hi
    I’m trying to have conditional format change the format of a cell to red if a condition is true based on a different cell and then copy it down about 30 cells with the based cell moving with it

    For ease of explaining:
    When I enter a number in E4, I want it to look at I3.
    If it’s not the same, change the font in E4 to red, so I will notice it.
    Then later when I enter a number in E5, I want it to look at I4, with the same condition.
    Then E6 compares with I5, etc
    When copy it down, it still looks at I3
    I tried to paste>>special>>all merging conditional format
    I also tried to use the format painter from the ribbon
    The conditional format formula adds the &’s ($I$3)
    When I change it to I3, it doesn’t work

    I can't make it work because the compare cell will change
    I don't really want to make a different conditional format rule in each E cell 30 times

    mike

  2. #2
    VBAX Mentor 大灰狼1976's Avatar
    Joined
    Dec 2018
    Location
    SuZhou China
    Posts
    479
    Location
    Hi selfteaching!
    Please refer to the Attachment.
    You can copy or drop the E column cells.
    Attached Files Attached Files

  3. #3
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,726
    Location
    Use OFFSET() in the CF formula and you should be able to copy the first CF and paste to the rest

    Capture.JPG
    ---------------------------------------------------------------------------------------------------------------------

    Paul


    Remember: Tell us WHAT you want to do, not HOW you think you want to do it

    1. Use [CODE] ....[/CODE ] Tags for readability
    [CODE]PasteYourCodeHere[/CODE ] -- (or paste your code, select it, click [#] button)
    2. Upload an example
    Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s) / Upload Files / Done
    3. Mark the thread as [Solved] when you have an answer
    Thread Tools (on the top right corner, above the first message)
    4. Read the Forum FAQ, especially the part about cross-posting in other forums
    http://www.vbaexpress.com/forum/faq...._new_faq_item3

  4. #4
    Thank you Paul_Hossler
    it worked like a charm

    Hi 大灰狼1976,
    I tried your formula, but I must of done something wrong. It formatted all the cellls red after I copied the formatting down and the reference cell stayed the same.

    Thanks for your help, though


    mike

  5. #5
    VBAX Mentor 大灰狼1976's Avatar
    Joined
    Dec 2018
    Location
    SuZhou China
    Posts
    479
    Location
    Hi selfteaching!
    I'm sorry, I may have misunderstood you.

  6. #6
    Not a problem. I'm glad you tried

    mike

Posting Permissions

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