Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
TimeZone (GMT-5) を表す -5 という値があるとします。
それを「Central DST」または C# と .NET フレームワークを使用した同様のテキストに変換するにはどうすればよいですか?
ありがとう!
.NET 3.5 を使用すると、TimeZoneInfo.GetSystemTimeZones() を使用してから、BaseUtcOffset を使用して一致が見つかるまで反復できます。
オフセットごとに複数のエントリが存在する可能性があるため、結果は多少恣意的なものになることに注意してください。