Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Return centesimal or millesimal seconds with Datetime()
Message
From
04/12/1998 13:36:53
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00164082
Message ID:
00164173
Views:
21
>John,
>
>>You can't. DateTime data types do not have the precision to be more detailed than seconds.
>
>It depends...
>
>In VFP we can't directly deal with subseconds. The OLE DateTime value though contains milliseconds. If something like VC++ is sending values to a VFP server those milliseconds can be a real PITA. I'll tell you it took a couple of hours tracking this little problem down and involved a hex file viewer.. it wasn't pretty *s*

You want to try something that will drive you crazy?

date1 = DATE()
date2 = date1 + .1

? date1,date2

? date1=date2 && = .F. !!!


I ran into this problem with some code that was adding non-integer values to dates. Boy, talk about a tough lesson to learn (and track down)!

You look at the dates in the debugger and everything looks cool. I guess some things are more equal than others no matter how equal they may "appear".
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform