+ Reply to Thread
Results 1 to 2 of 2

Changing cell fill colour based on date in cell - Multiple rows

  1. #1
    Registered User
    Join Date
    08-25-2010
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003
    Posts
    4

    Question Changing cell fill colour based on date in cell - Multiple rows

    Hello,

    I would really appreciate someone's help with this macro to be used in VBE. The macro is intended to change the cell fill colour to green if greater than 30 days from today, yellow if within 30 days from today and red if prior to today. This is currently working well but ONLY for one column (E). But I need this same macro to work for columns E thru W. I tried copying it 19 times and it works but is VERY slow. Also, could it be slow because it is running down to the last cell in each olumn, because row 1000 is plenty for each column for my use.

    Any help will be greatly appreciated! Thank you so much.

    Please Login or Register  to view this content.
    Last edited by ExcelNewb2010; 08-25-2010 at 10:44 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    06-17-2009
    Location
    Chennai,India
    MS-Off Ver
    Excel 2003,excel 2007
    Posts
    678

    Re: Changing cell fill colour based on date in cell - Multiple rows

    It is not clear how your configuration is anyhow I have slightly modified your macro. see whether this helps.. I could not check.
    I have kept your macro as it is though it can be tweaked.
    however as it is does it reduce the time for running.
    remember this is an event code. you have not used the variable "target" at all.
    why an event code? why not a conditional formatting which will be easier????

    Please Login or Register  to view this content.

+ 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