asp.net time zone settings

I want to let the end user choose their time zone and store this in to a database or web.config and use this setting throughout the application for setting the creation time to their time in stead of the servers time the application is running on.

How  can do this the best way?
Marc RosemaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Ryan ChongCommented:
My suggestion is to save the setting into database for 2 purposes (at least):

1. secure the confidential data
2. easier for maintenance and customization
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Shaun KlineLead Software EngineerCommented:
If your application will be used by multiple people across multiple time zones, and those people can view data from all users, this is not a wise idea, as it will skew the times seen by these other people. It is better to store your dates using the server time and use ASP.Net to localize the dates for the person viewing the information.

This link from Microsoft's website provides information on how to do this: https://msdn.microsoft.com/en-us/library/w7x1y988(v=vs.110).aspx
0
Paul MacDonaldDirector, Information SystemsCommented:
You can ask the client for their timezone and store that.  I would store all events with a timestamp set to GMT/UCT, then adjust the timestamp by the client's offset when you're showing it to the client.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.