Categories | Question details Back To List | ||
onEditCell event overrides onCheck event I am using checkboxes and normal text cells on my grid. First I tested checkboxes with mygrid.attachEvent("onCheckbox",doOnCheck); and checkboxes worked fine. Then I tested text edit cells with mygrid.attachEvent("onEditCell",doOnCellEdit); and edit mode worked fine. But when I try to test the checkboxes again I got no answer from my doOnCheck function. Instead, I got answer from doOnCellEdit function. I know that because I got answer from doOnCellEdit on stage 0, but got no value of whether is checked or not. If I comment the line mygrid.attachEvent("onEditCell",doOnCellEdit); everything works fine again with my checkboxes... I understand that checkboxes are also liked with that event, but why is this happening? Thanks in advance! Answer posted by Support on Feb 26, 2009 15:04 onEditCell event occurs each time when cell switched to edit state, checkbox|radio state changing generate normal edit events as well. In same time it doesn't override onCheckbox event ( both event will be fired when checkbox state changed ) >>If I comment the line mygrid.attachEvent("onEditCell",doOnCellEdit); everything works fine again with my checkboxes... Please be sure that all code paths in doOnEditCell ends with return true; onEditCell is blockable event, which means that returning non-true value from it will block edit operation ( which will stop checkbox state changing and firing of second event ) Answer posted by Alfonso Ortiz on Feb 26, 2009 15:43 Ok, I am going to make sure that all my functions attached to blockable events return true. Thank you! |