I am trying to convert an integer value to the timezone name it corresponds to. For instance: -6 would return either Central Standard Time or CST. I have looked at the TimeZoneInfo object but this appears to be able to only give me the local time zone or the integer value it corresponds with.
Clarification
I have an integer value, I do not know what the time zone is. I also do not care what time zone my server is running in. I need to take an integer value and get the Time Zone name.
Prior to Deprecation you could get the name of the timezone by:
// Get current time zone.
TimeZone zone = TimeZone.CurrentTimeZone;
string standard = zone.StandardName;
string daylight = zone.DaylightName;
Console.WriteLine(standard);
Console.WriteLine(daylight);
This would give you:
Mountain Standard Time
Mountain Daylight Time
I am looking for a solution like this where I have the offset and get the name in return.