Can i override the AutoFill behaviour for the below scenario?
I need to appy a specific calculation before autofilling the value in destination cells.
See the attached screenshot. I want to drag the value in JUN column of first row to the columns JUL, AUG and SEP. So i will select JUN cell and drag it to the right to copy the value (40 in this case) to JUL, AUG and SEP columns.
Hoewver, if the column is AUG, i need to copy twice the value in JUN… In other words, it should copy 80 to AUG column and 40 each to JUL and SEP columns. How can i override the default Autofill behaviour?
I tried overriding in beforeAutoFill hook, but no luck. Could you please suggest a possible solution?
Aleksandra, i tried updating the value to 80 in beforeautoFill hook, however, an AutoFill event is triggered after that (as observed in afterchange) that overwite it back to 40.
onBeforeAutofill = (hotInstance, start, end, data ) => {
It works with afterChange… but considering adding an afterAutoFill hook as a new feature… the more hooks you have, the more flexibility developers will get… Thank you
I have good news! We’ve just released 8.0.0-beta2 that fixes the mentioned issue. We won’t be closing this ticket now. It will be closed after we release the final 8.0.0 version of Handsontable.