BoldDeskWe are launching BoldDesk on Product Hunt soon. Learn more & follow us.
Hi Roman Suska,
Thanks for using Syncfusion products,
We have analyzed your query. We will let you know that we can achieve your requirement using our existing property “enablePersistance” (which is used to Enables or disables the state maintenance of DateTimePicker) in DateTimePicker control. By setting this value to “true” we can maintain the DateTimePicker value even after the post back the form.
Please find the below code snippet,
[_cshtml] @Html.EJ().DateTimePicker("SampleDateTime_1").EnablePersistence(true) @Html.EJ().DateTimePicker("SampleDateTime_2").EnablePersistence(true) |
For your convenience we have prepared the sample based on this. Please find the sample from below location
Please let us know if you have further queries.
Regards,
Sasikala Nagarajan
var startDateTimeObj = $("#dataRozpoczecia").data("ejDateTimePicker");
The jQuery code returns "undefined", so I think the control isn't created yet. How can I get the value set on the DateTimePicker after postback or page loading?
Greetings,
Roman Suska
Hi Roman Suska,
Sorry for the inconvenience.
We are unable to reproduce the reported issue. We have prepared the sample based on your requirement “To create object in $(window).load time” for the DateTimePicker control and the sample can be downloaded from the following location.
Sample Location : Sample
In this sample we can get the instance of the “DateTimepicker” and it is showcased with message.
Please check with the given sample. If still you face the problem, please revert us by modifying the sample based on your application along with replication procedure. This would be helpful for us to serve you or please share any screen shot of errors.
Please let us know if you have any concerns
Regards,
M.Manikandan
Hi Roman,
Thanks for the update,
Please let us know if you have any further assistance.
Regards,
Sasikala Nagarajan