hi all, good day.
how do i disable manual entry of date of birth filed.
user has to choose via date picker only
how do i achieve this.
the bug raised by my testing department
can any one help me.
i tried this i apply enable =false the filed is become disable even date picker is not opening if click on text filed .
Hi Rajesh,
Please mark my answer as a solution.
Thanks
Hi Pravi,
Is any solution available for reactive web for avoid manual date entry
Hello Rajesh,
Please check attached image to get it done.
Add Calendar widget with Icon beside it and set Calendar input trigger with that Icon and set input property
onkeypress: "return false;"
Amol Tupe wrote:
Thanks for reply,
working perfect!!
Use the below javascript to force user to select date from the Date Picker only.
/*JS For Validating Date Input*/ $(document).ready(function(){ $('.DateInputValid').on("cut copy paste",function(e) { e.preventDefault(); }); }); $(document).on("cut copy paste",".DateInputValid",function(e) { e.preventDefault(); }); function nokeypress(evt,InpId) { var charCode = (evt.which) ? evt.which : event.keyCode if (charCode !=13) { // $("#ValidationMessage_"+InpId.id).html("Please select date from calendar").show().fadeOut("slow"); return false; } return true; }
After adding this javascript to module, call this function "return nokeypress(event,"+txtCreatedTo.Id+");"
on "onkeypress" event. Also apply the style class "DateInputValid" to prevent user from cut, copy, paste.
Pravi Gupta wrote:
Thank you.