View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
DaveO DaveO is offline
external usenet poster
 
Posts: 94
Default Checking a Date format

Check out the funtion IsDate() and this should help!

I'm assuming, however you're using a VBA sub to do this?

"Kobus" wrote:

Hi

I have a cell in a worksheet that will hold a date. This date is used to
calculate the decayed value of radioactive sources. When the sheet is
deactivated I want to check whether the value in the cell is in a proper date
format. If not, then a message will be displayed and the sheet re-activated.
How can I check, using code, that the date is in a correct format?

Thanks all