Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Optional DateTime parameter in VB.NET????
Message
From
16/08/2004 17:16:14
 
 
To
15/08/2004 11:19:59
Max Fillmore
Essential Skills, Inc.
Lenexa, Kansas, United States
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00933162
Message ID:
00933693
Views:
17
Sorry, Max ... since I'm a C# programmer I don't know all the VB syntax. It looks like Rob gave you a good answer and one that I thought about giving myself, except for the fact that I was under the impression that VB.NET did not support overloaded methods ... but I guess I was wrong.

~~Bonnie



>Thanks Bonnie,
>
>What I was trying to convey was that I was trying to code the default clause on an option VB.NET paramater of DateTime type such as:
> Private Sub MySub(Optional ByVal MyParm as DateTime = DateTime.MinValue) as Integer
>or
> Private Sub MySub(Optional ByVal MyParm as DateTime = New DateTime DateTime.MinValue)) as Integer
>
>Neither of these will work of course because DateTime is a struct rather than an object and so cannot be an optional parm.
>
>Max Fillmore
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Reply
Map
View

Click here to load this message in the networking platform