Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 138
Default Checking if something is past due

I'm adding a function to an old Excel Macro. Basically, if Column H contains
Open and the date in Column C has passed, he wants the row to highlight
yellow. How do you check to see if a date has passed?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Checking if something is past due

Are you comparing dates in column C with a variable date input or just
today's date? Do the dates in column C include only dates in the past or do
they include future dates?

When you say "Open" for column H, are you referring to a stock price or the
text "Open"?

"Jonathan" wrote in message
...
I'm adding a function to an old Excel Macro. Basically, if Column H
contains
Open and the date in Column C has passed, he wants the row to highlight
yellow. How do you check to see if a date has passed?



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 203
Default Checking if something is past due

This should do the trick.

If Cells(Row, 8) = "Open" Then
If VBA.DateValue(Cells(Row, 3)) VBA.Now Then
Cells(Row, 3).EntireRow.Interior.ColorIndex = 6
End If
End If

"Jonathan" wrote:

I'm adding a function to an old Excel Macro. Basically, if Column H contains
Open and the date in Column C has passed, he wants the row to highlight
yellow. How do you check to see if a date has passed?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Past due function nannybears Excel Worksheet Functions 5 June 10th 09 01:14 AM
Past 30 montha NotGood@All Charts and Charting in Excel 1 May 22nd 08 09:23 AM
Spell Checking with checking cell notes jfitzpat Excel Discussion (Misc queries) 0 August 8th 07 10:26 PM
Checking range of cells for entry then checking for total Barb Reinhardt Excel Programming 1 October 13th 06 02:47 PM
Look up & past value Les Stout[_2_] Excel Programming 2 October 28th 05 03:09 PM


All times are GMT +1. The time now is 08:34 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"