+ Reply to Thread
Results 1 to 7 of 7

formula for cond. format

  1. #1
    Registered User
    Join Date
    01-30-2007
    Posts
    17

    formula for cond. format

    I was hoping I could solicit some help with the following conditional formatting formatting.

    In one cell I have a quanity.
    In another cell I have a cost.

    The cost cell should equal the quanity multiplied by 10,000

    So, the formula I want to put into the cond. formatting should check to make sure if the cost cell equals the quanity cell times 10,000. If yes, then no formatting.

    If no, then formatting.

    Thanks.

  2. #2
    Registered User
    Join Date
    07-28-2005
    Posts
    73
    Use cell value (a2) is not equal to a1*10000 then format into some color

    a1= qty
    a2= price

  3. #3
    Forum Expert
    Join Date
    01-12-2007
    Location
    New Jersey
    Posts
    2,127
    this is how I did it:
    A1=quantity
    b1=cost

    -Highlight the array (lets say you have 10 rows, highlight A1:B10)
    -Go to conditional format, select Formula, in the formula toolbar, type "=$B2 <>$A2*10000"
    -pick a color to highlight the incorrect rows.

    Hope this helps.

  4. #4
    Registered User
    Join Date
    01-30-2007
    Posts
    17
    Thanks. How do I copy the conditional formatting into other cells so that the cell reference changes.

    For example, the cond. formatting in B2 references A2.

    How do I copy the cond. formatting into B3 so that it references A3?

    Thanks.

  5. #5
    Forum Expert
    Join Date
    01-12-2007
    Location
    New Jersey
    Posts
    2,127
    if you have highlighted the range of cells when you set up the conditional format, it will automatically apply the format to all of them.

    if for some reason you want to apply this format to an additional row, you can copy one of the cells with the format, then do a paste special>formats to copy just the conditional format.

    I hope this helps

  6. #6
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  7. #7
    Registered User
    Join Date
    01-30-2007
    Posts
    17
    You guys rawk.

+ 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