>>>I have this method to detect if the server running the application is within a Dayling Saving Time period or not:
>>>
>>>
>>> ' Return if we are during summer time or not
>>> Public Function IsDaylightSavingTime() As Boolean
>>> Dim ldDateServer As DateTime = DateTime.Now
>>> Dim llDaylightSaveTime As Boolean = ldDateServer.IsDaylightSavingTime()
>>>
>>> Return llDaylightSaveTime
>>> End Function
>>>
>>>
>>>Then, I can use this result to establish a proper one hour offset to show the datetime in the proper format for the user.
>>>
>>>Javascript has a Date.getTimezoneOffset() function which returns the number of offset minutes from GMT. And, that is dynamic as per DST. So, I was wondering, instead of using the above .NET method to detect if we are or not within a DST period, which is then used to adjust the datetime for calculation, would there be a similar way as the javascript function to simply get the number of offset minutes from GMT as is from .NET? That would simplify some logics I have.
Dim result As Double = (DateTime.Now - DateTime.UtcNow).TotalMinutes
(assuming you are not worried about the elapsed ticks between retrieving the two values :-} )
I like a developer who thinks of everything ;-)