I would like the editor form to open and have the 3rd field have the focus. I know I have seen this in the examples or manual, but I can't seem to find it today.
This question has an accepted answers - jump to answer
https://editor.datatables.net/reference/type/form-options
this seems to open the editor on click of a row. I would rather use the edit button instead of on row click
The link Tangerine provided have links to initialization options such as formOptions.main. You can default the focus to the desired field.
formOptions.main
You can also use field().focus() in the open event to dynamically set the focus. The docs have an example.
field().focus()
open
Kevin
ah, yes. thanks
FMSUsersEditor.on('opened', function (e, node, data, items, type) { FMSUsersEditor.field('UserName').focus(); });
It looks like you're new here. If you want to get involved, click one of these buttons!
Answers
https://editor.datatables.net/reference/type/form-options
this seems to open the editor on click of a row. I would rather use the edit button instead of on row click
The link Tangerine provided have links to initialization options such as
formOptions.main
. You can default the focus to the desired field.You can also use
field().focus()
in theopen
event to dynamically set the focus. The docs have an example.Kevin
ah, yes. thanks