Make the .Text Calendar Control Go Global

Axle Munshine commented about a tip to make the .Text Calendar Control I posted some time ago, work in the French Canada or "fr-CA" language. As Axle says:
Here's the fix:
1) Add <%@import namespace="System.Globalization" %> in the declarations
2) In the TryParseDateTime() method add IFormatProvider culture = new CultureInfo("en-US", true); just before the "try {" code.
3) Change parsedDate = DateTime.Parse(dateString); for parsedDate = DateTime.Parse(dateString,culture); and it will work great!

posted @ Thursday, January 27, 2005 1:00 AM

Print

Comments on this entry:

# re: Make the .Text Calendar Control Go Global

Left by Jérôme Paradis at 2/2/2005 10:46 PM

Hi,

I'm Axle, you now know my real name. You can follow my blog to see an example in French, now that my blog is online.

I'll soon write an article in French that will explain everything I did for dotText, which will include your calendar control.

# re: Make the .Text Calendar Control Go Global

Left by Scott Willeke at 2/3/2005 11:26 AM

Great, let me know if I can help with anything.

# home loan mortgage

Left by home loan mortgage at 9/30/2006 9:05 PM

buzzing waits:surgical steal:cultivating diseases dinghy!sheller <A HREF="http://countrywide.dalmortgage.com/">countrywide</A> http://countrywide.dalmortgage.com/

Comments have been closed on this topic.