Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Converting DateTime variable to GMT or UTC
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00448793
Message ID:
00448977
Views:
11
>I agree, it should only be adding 6 hours for CST... and I guess we're not in daylight savings at the moment (I should've known that). It's adding 7 hours. Don't ask me why. I downloaded the code, added it to my project, and re-built it. I'm doing this:
>
>? DATETIME()
>DO UTC_TIME with DATETIME()
>
>I haven't modified UTC_TIME.PRG or any of the other files. I also tried it with the 'Automatically Adjust for Daylight Savings Time' checkbox in Control Panel both on and off. My time zone is set to Central Time, -06:00 hours GMT. It adds 7 hours every time.
>
>The only thing I can think of is I read somewhere that GMT is not always the same as UTC (and sometimes GMT != the current time in Greenwich, as I understand it).
>
>I just switched my time zone to Eastern Time, and it added 6 hours. I'm willing to bet you think it's my computer, and I'm inclined to agree. But what could be wrong that would throw it off that one hour? I would think if anything, it would be one hour less instead of one hour more for daylight savings... This makes no sense at all.

Let me download the files (I wrote them at home) and I'll check and post back.
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform