View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
CathyZ
 
Posts: n/a
Default date comparison help



"Dave O" wrote:

A tough one. Is startDates declared as a number, or date variable?
Are the dates in the column Excel-readable dates (a number representing
the elapsed days since 1/1/1900, then formatted as a date)? If the
cells are text instead of numbers and startDates is a string variable,
that would explain why the = sign works but not the = or <=.


I've sorted it out, what you wrote had me thinking, so I made one change in
my code and I think it works. When I made the worksheet active, I put the
cursor at the top of the column, but the first row had column headings, so I
now made the second row active, instead of the first and it worked. I
thought the program would just see the heading as a string and then go down
to the next row.

But thanks much for jogging my thinking cap.

CathyZ