Hello,
I’m trying to achieve a calendar cell selection, considering event on single or several days (in order to further create an event on the selected portion)
I’ve done it using a single master, instanciated for each corresponding timeslot in the timesheet.
Here are the template in RP8 & RP9
TimeSlotSelection.rp (71.6 KB)
TimeSlotSelection-rp9.rp (69.2 KB)
The mouseDown on a cell represent the start of the selection while the mouseUp reflect the end of the selection and I store X;Y position of thoses two cells.
Then comparing each cell’s X;Y against the first and last selected ones, i can select cell of the interval.
I’m near the end but i have a problem and a question…
The problem : While everything works fine for multiDay selection (from past to futur, and also reverse :D), on a singleday selection, why does the entire day is selected (whereas only the selected portion should be) ?
I used ELSEIF conditions in order to avoid further selection, but it does not seems to be taken in consideration, or that i’ve made a mistake in my conception but i can’t find it…
To investigate i’ve added some text within interaction of each selected cell to indicate associeted. That shows illegitimate trailing selection by the endDay condition, and leading one by the startDay condition.
Any clue ?
The question : I couldn’t find a better way of updating every single celle on the timeSheet than reloading the whole page… Does anyone see a better way ? On the overall concept, is there a simpler approach of doing so ?
Thank you very much for reading my problem, and thank you many more if you can provide any help.
Sincerly
Lionel B.