Hi All,
I am facing an issue with datetime control validation. I have two datetime controls date1 & date2 and the validation should be always date2 >date1.
I am using the below code for the validation and working properly in my local & U.S environment, but failed for German client. They have selected Date2 > Date1, But still the validation firing and prompting the error message Date 2 Should be > Date1.
<SharePoint:DateTimeControl ID="dtDateBegin" runat="server" DateOnly="true" LocaleId="1033" />
<SharePoint:DateTimeControl ID="dtDateEnd" runat="server" DateOnly="true" LocaleId="1033" />
<asp:CompareValidator ID="compDate" runat="server" ValidationGroup="personalGroup" Display="Dynamic" ForeColor="red" Type="Date" Operator="GreaterThan" ControlToCompare="dtDateBegin$dtDateBeginDate" ErrorMessage="DateEnd should be greater than DateBegin" ControlToValidate="dtDateEnd$dtDateEndDate"></asp:CompareValidator>
Let me know if you need any more information!
Thanks In Advance,
Kumar.
I am facing an issue with datetime control validation. I have two datetime controls date1 & date2 and the validation should be always date2 >date1.
I am using the below code for the validation and working properly in my local & U.S environment, but failed for German client. They have selected Date2 > Date1, But still the validation firing and prompting the error message Date 2 Should be > Date1.
<SharePoint:DateTimeControl ID="dtDateBegin" runat="server" DateOnly="true" LocaleId="1033" />
<SharePoint:DateTimeControl ID="dtDateEnd" runat="server" DateOnly="true" LocaleId="1033" />
<asp:CompareValidator ID="compDate" runat="server" ValidationGroup="personalGroup" Display="Dynamic" ForeColor="red" Type="Date" Operator="GreaterThan" ControlToCompare="dtDateBegin$dtDateBeginDate" ErrorMessage="DateEnd should be greater than DateBegin" ControlToValidate="dtDateEnd$dtDateEndDate"></asp:CompareValidator>
Let me know if you need any more information!
Thanks In Advance,
Kumar.