Results 1 to 14 of 14

"Fill" i.e. interior color a row based on a date value within that row

Threaded View

LiLi1 "Fill" i.e. interior color a... 03-27-2012, 10:59 PM
JBeaucaire Re: "Fill" i.e. interior... 03-27-2012, 11:36 PM
LiLi1 Re: "Fill" i.e. interior... 03-27-2012, 11:42 PM
JBeaucaire Re: "Fill" i.e. interior... 03-27-2012, 11:57 PM
LiLi1 Re: "Fill" i.e. interior... 03-28-2012, 12:08 AM
JBeaucaire Re: "Fill" i.e. interior... 03-28-2012, 12:26 AM
LiLi1 Re: "Fill" i.e. interior... 03-28-2012, 11:57 PM
JBeaucaire Re: "Fill" i.e. interior... 03-29-2012, 03:05 AM
LiLi1 Re: "Fill" i.e. interior... 03-29-2012, 10:15 PM
LiLi1 Re: "Fill" i.e. interior... 03-29-2012, 11:04 PM
LiLi1 Re: "Fill" i.e. interior... 04-10-2012, 01:47 PM
JBeaucaire Re: "Fill" i.e. interior... 04-10-2012, 07:11 PM
LiLi1 Re: "Fill" i.e. interior... 04-10-2012, 09:41 PM
JBeaucaire Re: "Fill" i.e. interior... 04-11-2012, 06:54 AM
  1. #1
    Forum Contributor
    Join Date
    01-14-2010
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    125

    "Fill" i.e. interior color a row based on a date value within that row

    I am trying to have the code take a range of cells and compare each row (each row contains a date) within that range to a cell and if the date contained in the row is before the current date to fill that row with an interior color. I am still rather new to VBA so likely I am just making some silly assumtions about how to word the coding. Thanks tons in advance for any help.

    Private Sub Highlight_Click()
    Dim Current_Date As Date
    Current_Date = Worksheets("Name").Range("H1").Value
    
    LastRow = [A5].End(xlDown).Row
    ActiveSheet.Range("A5:H" & LastRow).Select
    If Range("E5").Value <= Current_Date Then Row.Select
    
    With ActiveRow.Interior
    .ColorIndex = 36
    .Pattern = xlSolid
    End With
    
    Do Until Cell.Value Is Empty
    Loop
    
    End Sub
    Last edited by LiLi1; 04-10-2012 at 01:40 PM.

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