Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I represent empty date

Status
Not open for further replies.

TonyScarpelli

Programmer
Jan 23, 2003
361
US
What is the syntax for representing an empty date?

It seems that ## doesn't work.

Thanks.


Tony Scarpelli
Clinical Engineering Dept.
Maine Medical Center
Portland, Maine 04102
 
In my current FoxPro application, my users have been used to entering dates in certain ways. I have a FoxPro function that formats dates, that the user enters, into a very specific form. For instance if they enter ',' or '.' or '/', it represents today and they see Aug. 2, 2004 on the screen. Also if they enter other formats, they see the same 'Mon. day, year' format in the entry field.

I am turning this FoxPro function into a VB .NET function which returns a 'date' type. If there is an error in the FoxPro function it returns an empty date '{}'. In VB .NET I was trying to also return an empty date which I though would be '##', but I guess not.

I have had to add code that checks for the error and return and empty string '""' instead. I got it to work all right, but it would take less code to just return an empty date type.

Thanks.


Tony Scarpelli
Clinical Engineering Dept.
Maine Medical Center
Portland, Maine 04102
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top