Mobile Interaction\Calendar selected date marker gose back to current data

Hi when i use the Interaction\Calendar block and change the event List it changes the markers date from the selected date to the current even though StartDate still is the selected date(SelectInteral set to false). Dose any one know why this happens and if i can do anything about it?

How it looks on screen

Solution

Hi Eric,

The reason is that the whole pikaday object gets re-created when you change the event list, and in the process loses track of what month he was on or what date(range) was selected.

I guess the normal use case would be to set up the event list once, then use the date picker to pick a date and move on.  It's is probably not designed to support updating the events while it's being used for picking a date.

So do you really need to change the event list after initialisation of the date picker ?

The underlying library (pikaday) does support setting a selected date / selected range and setting the month to be viewed, so if you really need this, you could modify a copy of the outsystems interaction/date picker, there's only a few spots that need to be changed.

Dorine

Solution

Thanks Dorine i understand i think im gone change the design and maybe look in too the pikaday library later.

// Eric