Problem with disable dates, when using culture setting
Hi I cant get this simple sample code to work. Any ideas?
Code:
<%@ Page Language="C#" %>
<%@ Register Assembly="Coolite.Ext.Web" Namespace="Coolite.Ext.Web" TagPrefix="ext" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<script type="text/javascript">
</script>
<title></title>
<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{
//Sets the culture on the page
string strCulture = "da-DK";
Page.Culture = strCulture;
System.Globalization.CultureInfo ciCulture = new System.Globalization.CultureInfo(strCulture, true);
ScriptManager1.Locale = ciCulture;
//--
string[] strDisabledDates = new string[1];
strDisabledDates[0] = DateTime.Now.AddDays(1).ToShortDateString();
dpDatePicker.DisabledDates = strDisabledDates;
}
</script>
</head>
<body>
<form id="form1" runat="server">
<ext:ScriptManager ID="ScriptManager1" runat="server">
</ext:ScriptManager>
<ext:DatePicker runat="server" ID="dpDatePicker"></ext:DatePicker>
</form>
</body>
</html>
Thanks!
/Mikael
RE: Problem with disable dates, when using culture setting
Hi guys, do you need more info on this one? Maybe I was beeing unclear?
/Mikael
RE: Problem with disable dates, when using culture setting
Hi Mikael,
We will investigate it, it seems need make some changes.
At this moment use for "da-DK" culture
strDisabledDates[0] = DateTime.Now.AddDays(1).ToString("dd/MM/yy", CultureInfo.InvariantCulture);
*
RE: Problem with disable dates, when using culture setting
Ok thank vladimir.
Keep me posted, when the changes has been made.
/Mikael
RE: Problem with disable dates, when using culture setting
Hi Mikael,
We're making some changes to the .DisabledDates property, which should be implemented today.*
RE: Problem with disable dates, when using culture setting
Excellent! Thank you!
/Mikael