Search code examples
codenameone

How to set the displayed start and end date in the Codename One date picker?


I would like to display a date picker in my app, but I need to set the the limits on the earliest and latest shown dates. How can I do it with Codename One PickerComponent? Or are there any other better ways to do it?

This is the example of what I have right now


Solution

  • Solution found - my PickerComponent must include both setStartDate() and setEndDate(). Example -- enter image description here