Home:ALL Converter>Determine if a DateTimeOffset is Daylight Saving Time

Determine if a DateTimeOffset is Daylight Saving Time

Ask Time:2017-10-24T03:59:58         Author:Jarrette

Json Formatter

DateTime already has a function called IsDaylightSavingTime that returns a boolean if that DateTime falls under Daylight Saving Time or not. However, it uses server (local) time to make that determination.

In my Web services I have a DateTimeOffset for each of my clients throughout the country. How can I determine IsDaylightSavingTime from a DateTimeOffset?

Author:Jarrette,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/46897533/determine-if-a-datetimeoffset-is-daylight-saving-time
yy