Editing date in textbox?

D

Don Wiss

When a date is required in a spreadsheet cell it is real easy to use Data
Validation. But if input is being entered in a Form, one only has a
textbox. (I am not interested in any date input control, as nothing is
easier to input than simply typing a date.) I don't see any easy way to
edit that the date is valid. I am planning to try assigning the input to a
date data type and capturing any errors. Is there any other way?

Thanks, Don <donwiss at panix.com>.
 
Z

zantor

Hi Don,

You will have to use the 'IsDate' funcion:

If IsDate(TextBox1) = False Then
MsgBox "Not a valid date."
Else
MsgBox "Valid date"
End If
 
D

Don Wiss

You will have to use the 'IsDate' funcion:

If IsDate(TextBox1) = False Then
MsgBox "Not a valid date."
Else
MsgBox "Valid date"
End If

Thank you. I was not aware of Isdate. I will try this tomorrow at work, and
hope that it exists in Excel 97.

Don <donwiss at panix.com>.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top