Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Optional DateTime parameter in VB.NET????
Message
From
13/08/2004 11:56:57
Max Fillmore
Essential Skills, Inc.
Lenexa, Kansas, United States
 
 
To
All
General information
Forum:
ASP.NET
Category:
Other
Title:
Optional DateTime parameter in VB.NET????
Miscellaneous
Thread ID:
00933162
Message ID:
00933162
Views:
71
I'm trying to write a subroutine with an optional DateTime parameter. Problem is I can't seem to code a default for it. I've tried "= Nothing", "= New DateTime(DateTime.MinValue)", and "= New DateTime(CType(0, Long))". The compiler rejects them all. I would like to default the parameter to Nothing then be able to check it inside the sub with "If MyDateTime is Nothing Then".

Has anybody else run into this?

Thanks.
Next
Reply
Map
View

Click here to load this message in the networking platform