How to set default time zone in ASP.Net Application

前端 未结 1 481
余生分开走
余生分开走 2021-01-11 19:52

Hi i have created the asp.net web application without considering the time zone. I am using directly the DateTime.Now function. Actually that returns datetime in server conf

相关标签:
1条回答
  • 2021-01-11 20:25

    TimeZone.CurrentTimeZone is used for the time zone on the computer where the code is executing. Check these links: http://msdn.microsoft.com/en-us/library/system.timezone.currenttimezone.aspx

    http://msdn.microsoft.com/en-us/library/system.timezoneinfo.local.aspx

    0 讨论(0)
提交回复
热议问题