LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default If a cell value is today's date, than increace cell value by one

Hi, I would like to compare a columns that contains date (2005/11/30)
to today's date.
If it is, than increase a cell by one.
I'm having problem with the format

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Target, Columns("A1:A10")) Is Null Then
;so it skips the empty cells
Application.EnableEvents = False
if the cell is today's date than ;not sure
of the format
Range("A1").Value = Range("A1").Value + 1
Application.EnableEvents = True
End If
End Sub

Thanks

 
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
If cell is blank automatically enter today's date in the same cell LCTECH001 Excel Discussion (Misc queries) 22 April 5th 23 02:50 PM
conditional formatting for cell date to equal today's date Sistereinstein Excel Worksheet Functions 2 September 10th 12 07:53 PM
date in Cell to change colors if the date is beyond today's date Pete Elbert Excel Discussion (Misc queries) 2 June 6th 09 06:31 AM
Referencing Cell Next To Today's Date Cell Docktondad Excel Discussion (Misc queries) 5 May 16th 07 10:25 PM
text and today's date in 1 cell rexie3 Excel Discussion (Misc queries) 5 February 8th 07 10:38 PM


All times are GMT +1. The time now is 01:23 PM.

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

About Us

"It's about Microsoft Excel"