When avoiding the issue is not an option, I use DateTime.MinValue as a null-value marker.
-- Rune Huseby > -----Original Message----- > From: Bill Bassler [mailto:[EMAIL PROTECTED] > Sent: 9. oktober 2003 19:59 > To: [EMAIL PROTECTED] > Subject: Elegant way of handling "nulls" when assigning to > the DateTime structure > > > When for example retrieving a null value from a database ... > because the > DateTime structure cannot have null reference assigned to it ... > you end up having to check every time you want to attempt to > assign it. > > It appears that you can use implicit operator to create wrapper around > DateTime to get around these issues. Is there a more elegant > way or there > something that I'm completely missing? > > =================================== > This list is hosted by DevelopMentor(r) http://www.develop.com > NEW! ASP.NET courses you may be interested in: > > 2 Days of ASP.NET, 29 Sept 2003, in Redmond > http://www.develop.com/courses/2daspdotnet > > Guerrilla ASP.NET, 13 Oct 2003, in Boston > http://www.develop.com/courses/gaspdotnet > > View archives and manage your subscription(s) at http://discuss.develop.com =================================== This list is hosted by DevelopMentor� http://www.develop.com NEW! ASP.NET courses you may be interested in: 2 Days of ASP.NET, 29 Sept 2003, in Redmond http://www.develop.com/courses/2daspdotnet Guerrilla ASP.NET, 13 Oct 2003, in Boston http://www.develop.com/courses/gaspdotnet View archives and manage your subscription(s) at http://discuss.develop.com
