Last post May 07, 2009 08:37 AM by SGWellens
Member
7 Points
81 Posts
May 07, 2009 06:46 AM|attawba|LINK
hi,
is it possible to convert a datetime to timespan??
i want to di this :
timespan = datetime +timespan
any ideas?
thanks
All-Star
54508 Points
14111 Posts
May 07, 2009 07:03 AM|mudassarkhan|LINK
Read here
http://dotnetguts.blogspot.com/2007/06/understanding-datetime-and-timespan-in.html
101931 Points
20703 Posts
May 07, 2009 07:05 AM|MetalAsp.Net|LINK
DateTime has a a Ticks property; One of the TimeSpan constructors takes a ticks value. if you combine the two you should be able to convert a datetime to a timespan.
124328 Points
10142 Posts
May 07, 2009 08:37 AM|SGWellens|LINK
attawba hi, is it possible to convert a datetime to timespan?? i want to di this : timespan = datetime +timespan any ideas? thanks
Think of a datetime as a point.
Think of a timespan as the distance between two points.
It doesn't make sense to convert between them.
Member
7 Points
81 Posts
convert datetime to timespan
May 07, 2009 06:46 AM|attawba|LINK
hi,
is it possible to convert a datetime to timespan??
i want to di this :
timespan = datetime +timespan
any ideas?
thanks
All-Star
54508 Points
14111 Posts
Re: convert datetime to timespan
May 07, 2009 07:03 AM|mudassarkhan|LINK
Read here
http://dotnetguts.blogspot.com/2007/06/understanding-datetime-and-timespan-in.html
Blog: ASPSnippets | Forum: ASPForums | Company: Excelasoft
All-Star
101931 Points
20703 Posts
Re: convert datetime to timespan
May 07, 2009 07:05 AM|MetalAsp.Net|LINK
DateTime has a a Ticks property; One of the TimeSpan constructors takes a ticks value. if you combine the two you should be able to convert a datetime to a timespan.
All-Star
124328 Points
10142 Posts
Re: convert datetime to timespan
May 07, 2009 08:37 AM|SGWellens|LINK
Think of a datetime as a point.
Think of a timespan as the distance between two points.
It doesn't make sense to convert between them.
My blog