what would be the CalendarLayout called in case of :WebDatePicker
<igedit:WebDatePicker ID="statrdate" runat="server" Width="130px" AllowNull="True" Enabled="True" AutoCloseUp="true" ShowDropDown="False" NullDateLabel="Select End Date" NullValueRepresentation="DateTime_MinValue" > <ClientSideEvents ValueChanging="handle_ToDateChanged" InvalidValueEntered="handle_InvalidDateEntered" Blur="handle_ToDateOnBlur" /> <a:CalendarLayout DayNameFormat="FirstLetter" FooterFormat="" ShowFooter="False" ShowNextPrevMonth="False" ShowTitle="False"> <CalendarStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False"> </CalendarStyle> <SelectedDayStyle CssClass="SelectedDay" /> <DayHeaderStyle CssClass="DateTimeDayHeader" /> <TitleStyle CssClass="DateTimeTitle" /> <DayStyle CssClass="DateTimeDay" /> </a:CalendarLayout> </igedit:WebDatePicker>
Hello,
WebDatePicker control does not have NullValueRepresentation property.
However there is such property in WebDateChooser class, which inherits the Infragistics.WebUI.WebSchedule.Namespace: http://help.infragistics.com/doc/ASPNET/2014.1/CLR4.0/?page=Infragistics4.WebUI.WebSchedule.v14.1~Infragistics.WebUI.WebSchedule.WebDateChooser~NullValueRepresentation.html
If you have any other questions, please let me know.
Sincerely,
Tsanna
how is NullValueRepresentation="DateTime_MinValue" used in the WebdatePicker?
I dont see, any equivalent property for that in the WebdatePicker
Hello Arjun,
Thank you for posting in our community.
If you want to get reference to the WebDatePicker control on the client, then you can use the following:
var wdp=$find("WebDatePicker1")
The client side events in the new controls accept two parameters by default, which are: sender (the object that causes the event to raise) and eventArgs(the arguments of the respective event). In your case ValueChanging event of WebDatePicker will look like:
function ValueChanging(sender, eventArgs){...}
The following table lists all members exposed by DatePickerClientEvents class: http://help.infragistics.com/doc/ASPNET/2014.1/CLR4.0/?page=Infragistics4.Web.v14.1~Infragistics.Web.UI.EditorControls.DatePickerClientEvents_properties.html
Please take a look at the documentation link and let me know if you have any further questions.
I have javascrpt event for webdatechooser which i am looking to upgrade to webdatepicker , my webdatepicker clientside event is valuechanging how ever when trying to rewrite the code i could not understand the purpose of the oDate in wdc to be able to rewrite in wdp. kindly help asap.
function wdc_calenderValueChanging(oCalendar, oDate, oEvent)
{ validateFromDateChanged(oDate); oEvent.Cancel = true;}
function validateFromDateChanged(oDate) {var fromDateControl = igdrp_getComboById(StartDateId); / / var StartDateId = '<%=StartDate.ClientID%>'; var toDateControl = igdrp_getComboById(EndDateId); // var EndDateId = '<%=EndDate.ClientID%>'; validateFromDateChanged(fromDateControl, toDateControl, oDate);
}
function validateFromDateChanged(fromDateControl, toDateControl, oDate) { var fromDateTime = new Date(); fromDateTime = fromDateControl.getValue(); if (fromDateTime != null && oDate != null) { fromDateTime.setFullYear(oDate.getFullYear()); fromDateTime.setMonth(oDate.getMonth()); fromDateTime.setDate(oDate.getDate()); } var toDateTime = toDateControl.getValue();
if (toDateTime <= fromDateTime) { var temp = new Date(fromDateTime.getFullYear(), fromDateTime.getMonth(), fromDateTime.getDate(), fromDateTime.getHours(), fromDateTime.getMinutes(), fromDateTime.getSeconds()); toDateControl.setValue(temp); } fromDateControl.setValue(fromDateTime);}
Also i am upgrading from webdateshooseer to webdatepicker , what shuld the following code me replaced with in WebDatepicker?
var fromDateControl = igdrp_getComboById(StartDateId);