Click here to Skip to main content
15,894,955 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
There are different date and time in client side in my website.But the date and time are shown in server side is different. So I can not count real time for some information depends on time. What to do reply me.
Posted
Comments
Sandeep Mewara 13-Oct-12 16:08pm    
Store a standard time. Lets say GMT based. store all value accordingly and display in UI based on time zone of server.

use system.timezoneinfo class. it will only provide you server time zone info.
 
Share this answer
 
I don't know if this is what your looking for.

C#
// Make a new timer set its 
// Name = tmrClock
// Enabled = true
// Interval = 1000
// Make a new label set its
// Name = lblClock
// BorderStyle = FixedSingle
// Text = ""
// TextAlign = MiddleCenter

DateTime dtCurrentTime = new DateTime.Now;
lblClock.Text = dtCurrentTime.ToLongTimeString();
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900