Calendar Control Localization

K

Kevin Yu [MSFT]

Hi Stephen,

We have reviewed this issue and are currently researching on it. We will
update you ASAP. Thanks for your patience!

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."
 
S

Steven Cheng[MSFT]

Hi Stephen,

Thanks for your posting. As for the Globalization of the asp.net Calendar
control, we just need to set the appropriate CultureInfo for the web
request's current executing thread. For example:

private void Page_Load(object sender, System.EventArgs e)
{
System.Globalization.CultureInfo ci = new
System.Globalization.CultureInfo("ar-EG");

ci.DateTimeFormat.Calendar = new System.Globalization.HijriCalendar();
System.Threading.Thread.CurrentThread.CurrentCulture = ci;
System.Threading.Thread.CurrentThread.CurrentUICulture = ci;
.....
}

Then, the buildin ASP.NET web controls will render the appropriate style
html contents according to the current thread's UICultureInfo. And to use
the HijriCalendar, we can create a HijriCalendar instance and assign it to
the CultureInfo object's DataTimeFormat.Calendar property( see above).

Hope helps. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top