currently, date picker component left and right arrow changes on monthly basis. Is there a way to add additional left and right arrows that will change year (from Sep 2014, clicking on that additional left arrow should go to Sep 2013)?
currently, date picker component left and right arrow changes on monthly basis. Is there a way to add additional left and right arrows that will change year (from Sep 2014, clicking on that additional left arrow should go to Sep 2013)?
Hi,
Please run the following code for a datepicker named mobiledatepickerName to switch years:preApperyio("mobiledatepickerName").datapickerRoot.datepicker({"changeYear": true});/pre
Sorry. Can you tell me where to add this code?
When I added on page load (where I have the datepicker), it is adding a new date picker with the year. If I do like this, I need to complete implement onclick etc etc all over again.
Hello,
You should call this code on the event load. This code will add the possibility of choice of a year in the existing datepicker.
I am having same issue ....I don't see where you can add on event load ? I can only see page load and page show . Please help
Hello,
You can use this code in "page show" event handler.
Regards.
Hello Yurii,
I tried the above code using page show with my calender selector instead of
"mobiledatepickerName" and what happens is that i get the existing calendar and a second calendar which has the year scroller in it underneath . This is not correct
Hello,
Please use following JS code:
pre
//Where "mobiledatepicker_73" is your datepicker component name.
Apperyio("mobiledatepicker_73").datepicker_dataPickerOptions.changeYear = true;
Apperyio("mobiledatepicker_73").initializeDataPicker()
/pre
Regards.
Yurii,
Thank you so much, this worked as you described. However when I select a year from the drop down menu the calender looses the style size color swatch etc that the original calendar has . Is there a way to keep the orignal calender style ?
Thanks again
Hello,
Please show us before and after this issue screenshots.
Regards.