Dates are stored in the database as UTC. How do I render them in the report as Local Date?
Thanks.
UTC Date to Local Date
-
- Posts: 2
- Joined: Wed Feb 13, 2013 3:20 am
Re: UTC Date to Local Date
Hello,
You can use the following code:
Please check the following link:
http://stackoverflow.com/questions/2580 ... n-database
Thank you.
You can use the following code:
Code: Select all
{TimeZoneInfo.ConvertTimeFromUtc(DataSource.ColumnName, TimeZoneInfo.FindSystemTimeZoneById("AUS Eastern Standard Time")).ToLocalTime()}
http://stackoverflow.com/questions/2580 ... n-database
Thank you.
-
- Posts: 2
- Joined: Wed Feb 13, 2013 3:20 am
Re: UTC Date to Local Date
Yes, that works after adding reference to System.Core.Dll to the Report. Thanks for your help.
Re: UTC Date to Local Date
Hello,
We are always glad to help you!
Thank you.
We are always glad to help you!
Thank you.