locked
SetSystemTime - Day Light Saving RRS feed

  • Question

  • The documentation on "SetSystemTime" suggests that you pass it the current date and time as UTC (GMT) time.

     

    Why is it then that when I call it, passing it a GMT time it is still adding an hour for day light saving.

    The locale is correctly set to London i.e. Not in Day light Saving as of Sunday (October 31 2010).

     

    This is crazy. What is the best way to set the system time given a GMT time. C++ application.

     

    Need a resolution fast, preferably one that does not involve a code change.

     

    Any help would be great.

     

    dh

    Tuesday, November 2, 2010 4:37 PM

Answers

  • why can't you try SetTimeZoneInformation() function first?

    http://msdn.microsoft.com/en-us/library/aa915071.aspx


    Vinoth.R http://vinoth-vinothblog.blogspot.com http://www.e-consystems.com
    • Marked as answer by dhToday Wednesday, November 3, 2010 10:22 AM
    Wednesday, November 3, 2010 8:19 AM

All replies

  • why can't you try SetTimeZoneInformation() function first?

    http://msdn.microsoft.com/en-us/library/aa915071.aspx


    Vinoth.R http://vinoth-vinothblog.blogspot.com http://www.e-consystems.com
    • Marked as answer by dhToday Wednesday, November 3, 2010 10:22 AM
    Wednesday, November 3, 2010 8:19 AM
  • Thanks Vinoth,

     

    I now check the status on DLS first using your suggestion, which works fine.

    Wednesday, November 3, 2010 10:21 AM