Solved

Set Timezone in ASP.Net

Posted on 2014-10-27
4
133 Views
Last Modified: 2014-11-04
How do I set the timezone in ASP.Net?  When an individual visits the website I want everyone to see the time, calendar, etc. as it is in a particular timezone.
0
Comment
Question by:Ray Turner
  • 2
4 Comments
 
LVL 1

Expert Comment

by:kayhustle
ID: 40407006
Not sure exactly what you mean.  Are you looking to load an asp .net web page and show time variables in the page in the respective user's time zone?
0
 
LVL 19

Accepted Solution

by:
mrwad99 earned 500 total points
ID: 40407021
You need to use the TimeZoneInfo class to achieve this.  You can enumerate all time zones using the GetSystemTimeZones() method, selecting just the ones you want.

Here is the exact article I used for reference when I had to research doing roughly the same thing:  http://www.dotnetcurry.com/showarticle.aspx?ID=593

HTH
0
 

Author Comment

by:Ray Turner
ID: 40407183
To kayhustle,

I want to all time/date related info (calendar, etc.) to show values based on the current time in a specific timezone.   For example; I want to display the calendar based on the current time/date in New York City.  I want convert the server date/time to the current date/time in New York City.
0
 

Author Closing Comment

by:Ray Turner
ID: 40422958
Thanks!
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question