JavaScript after AjaxEvent on grid

I use AjaxEvent to treat OnClick on records of a grid.
How can I activate a JavaScript or do actions like grid refresh after the return from the Ajax call ?

It seems JavaScript method, and nearly nothing is usable in PHP part of AjaxEvent…

Has anybody faced the situation ? And found a solution …


This is the function that you call at the end of whatever you are doing, it will refresh the grid.

Thanx !
That’s great at least to refresh the grid.
Do you also have an idea on how to display a nice message before that, like a Sweet Alert ?
The best I can do for now is returning a string from PHP and activate the “Ajax Debug”, which is really not nice…

sc_ajax_message($message, $title);

That may not work on a grid so try sc_alert instead.

sc_ajax_message works like a charm, indeed.
Too easy !! :joy:
It’s a pitty those macros are not listed in the available macros when editing the php code.

Thanx again

1 Like