Remarks ...
The sample proposed by Reuben was the solution that we've initially programmed but this is not really a good solution because of sort problem ...
If you try that cod after the "on action my_insert" is validated and the array is sorted the new row "dissapear" from the screen and for the end user is very strange ...
With the "ON INSERT" the row stay at the position inserted until the display array is refreshed
Regards
My example probably should have a DIALOG.setCurrentRow("scr", r) at the end to set the current row in the array to the row that has just been inserted.
However you said "... and the array is sorted ...". I would be curious as to how at this point you do your sort. Is the user clicking slowly twice on the header to redo the sort, or are you calling array.sort() ?
You should also note the existence of an fglprofile entry "currentRowVisibleAfterSort"
https://4js.com/online_documentation/fjs-fgl-manual-html/#fgl-topics/c_fgl_fglprofile_004.html. Default value is false. If you set this to true, add the line above to set the current row to the line just added, then after inserting the row if you redo the sort by clicking slowly twice on the column header, then I think you will see what you want to see.
If you have explicitly added an array.sort(), then you might not get results you anticipate, for the same reasons that you use DIALOG.insertRow and not array.insertElement. Perhaps we should have a DIALOG.reapplySort so that the user does not have to slowly click twice on the header ...
Reuben