+ Reply to Thread
Results 1 to 6 of 6

Changing cells color without clicking command button

  1. #1
    Registered User
    Join Date
    02-12-2008
    Posts
    48

    Changing cells color without clicking command button

    Hi. Thanks for this great forum and all its contributors. I have learnt a lot from this. I have a problem here and hope some kind souls will help. Thanks!

    Problem :
    I need the color of cells B1 to B10 to change according to changes I make to its contents/text value *without* clicking a command button.

    A1 = Pricing
    A2 = Contract
    A3 = Implement

    Cell range = B1:B10
    If B1 = Pricing, color it blue.
    If B1 = Contract, color it red
    If B1 = Implement, color it yellow.
    Repeat for B2 to B10.

    Any help is greatly appreciated!!!

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello grumpyguppy,


    Conditional formatting will do this for you based on your formulas. Select the cells and under Format select Conditional Formatting... and follow the prompts.

    Sincerely,
    Leith Ross

  3. #3
    Registered User
    Join Date
    02-12-2008
    Posts
    48
    Thanks Leith for the suggesting conditional formatting. My actual range of cells to format is huge, so formatting these one by one is not ideal. I need VBA codes. Thanks!!!

  4. #4
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229
    The conditional formatting can be copied from one cell to the huge range.
    _
    ...How to Cross-post politely...
    ..Wrap code by selecting the code and clicking the # or read this. Thank you.

  5. #5
    Registered User
    Join Date
    02-12-2008
    Posts
    48
    Thanks mikerickson. Conditional formating has only max 3 conditions. My number conditions is more. How do I use conditonal formating in this case? Thanks for helping!

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    How many conditions do you have? Here's some example code that you can adapt

    Please Login or Register  to view this content.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

+ 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