I am developing an ASP.NET based application using Visual Studio 2005. The back-end database is Oracle.
Our Windows OS - is Thai Language. When i try to enter the date in my ASP.NET app - it saves the date in the English Calendar Year format (i.e. it stores the date as 2006) - which is correct. But, when i search this record and view
it - it displays the date in Thai Calendar Date (i.e. 2549 - which is correct as per Thai calendar because it is 2006 + 543).
But, we want to see the Date in English Calendar date format.
How and where can we change this in our ASP.NET application?
Check CultureInfo.InvariantCulture property in System.Globalization in the first link and the second link shows how to create culture neutral datetime in SQL Server the idea is the
same it will help you with Oracle DateTime.The last link is DateTime.Parse method you can use to create culture specific date.Hope this helps.
None
0 Points
2 Posts
Showing Date in English Year format - rather than Thai Calendar format
May 31, 2006 05:16 AM|Yanni|LINK
I am developing an ASP.NET based application using Visual Studio 2005. The back-end database is Oracle.
Our Windows OS - is Thai Language. When i try to enter the date in my ASP.NET app - it saves the date in the English Calendar Year format (i.e. it stores the date as 2006) - which is correct. But, when i search this record and view it - it displays the date in Thai Calendar Date (i.e. 2549 - which is correct as per Thai calendar because it is 2006 + 543).
But, we want to see the Date in English Calendar date format.
How and where can we change this in our ASP.NET application?
Please advise me.
Thanks,
Yanni
Contributor
4150 Points
5249 Posts
Re: Showing Date in English Year format - rather than Thai Calendar format
May 31, 2006 12:49 PM|Caddre|LINK
Check CultureInfo.InvariantCulture property in System.Globalization in the first link and the second link shows how to create culture neutral datetime in SQL Server the idea is the same it will help you with Oracle DateTime. The last link is DateTime.Parse method you can use to create culture specific date. Hope this helps.
http://msdn.microsoft.com/en-us/library/4c5zdc6a.aspx
http://www.karaszi.com/SQLServer/info_datetime.asp
http://msdn.microsoft.com/en-us/library/1k1skd40.aspx
None
0 Points
2 Posts
Re: Showing Date in English Year format - rather than Thai Calendar format
May 31, 2006 10:09 PM|Yanni|LINK
Thanks for your kind help.
I will try as per the links you have suggested and let you know.
Best Regards,
Shailesh