I have a dhtmlXGridObject with the block selection enabled. I’m trying to put onClick event on header elements of the grid to show popups.
The event working good but it immediatly loosing the focus of the header element I have clicked on it so the instruction on my onBlur event are executed immediatly after the click and my popup disappears.
I have the same problem with the dhtmlx combo I put in the header, the list of options appears and disappears immediately.
The cause of the blur event is the click event in the enableBlockSelection function of dhtmlxgrid_selection.js.
Have you any solution to keep the block selection on Grid enabled and the possibility to focus the headers element by a onClick event ?
I thank you in advance for your help.
Please, try to wrap your events in the dhtmlxEvent form:
If the problem still occurs for you please, provide a simple example, where the problem can be reconstructed.
Thanks for response. I’ve tried to wrap my event in the dhtmlxEvent function but nothing change and it’s not a solution for the combo because I juste create dhtmlx combo elements and I don’t attach any events on it.
The only solution I found is to attach a click event on the container of the combo and call the event.stopPropagation();
Thanks for help
Could you please, provide a complete demo or share a demo link, where the described problem can be reproduced locally.
Here you can find a tutorial about creating a complete demo: