When setting the date format for the WebDateChooser I only see "Long" and "Short" as acceptable values.
I want to show a short day name and a short date: "Wed 01/16/08"
Is this possible with the webdatechooser?
Thanks for your help.
Hi,
The Format defines only date pattern for not-focused state. In input mode WebDateChooser can only use "digit" patterns, and only for all 3 fields (day, month, year).
Both those patterns are defined by CurrentCulture or they can be customized on level of particular control. For example, set Format="Long" and implement Page.OnLoad by something like below:
protected void Page_Load(object sender, EventArgs e){ System.Globalization.CultureInfo ci = System.Globalization.CultureInfo.CreateSpecificCulture("en-EN"); ci.DateTimeFormat.LongDatePattern = "ddd MM/dd/yy"; ci.DateTimeFormat.ShortDatePattern = "MM/dd/yy"; this.WebDateChooser1.CalendarLayout.Culture = ci;}
Regards,ViktorInfragistics web team
Hi Viktor,
I am getting this error ('Infragistics.WebUI.WebSchedule.CalendarLayout' does not contain a definition for 'Culture') while trying to apply your solution.
Does you have any suggestion on this?
I am using Infragistic V5.2.
Thanks.
Regards,
Say Chao
I do not remember in which version Culture was added to CalendarLayout. If 5.2 does not contain that, then you may consider upgrade to the latest version or use Culture of CurrentThread (that will affect all controls on page, but not only WebDateChoosers).
Thanks for the explanation.
I apply the Culture to the CurrentThread as you mentioned.
Thanks & Best Regards,