Arbortext Command Language > Callbacks > doc_add_callback > tbl_obj_add Callback Type
  
tbl_obj_add Callback Type
Function prototype:
function funcname (doc, before, after, op)
tbl_obj_add is called before a Grid, Column, or Row is inserted into an existing table.
Arguments
doc is the identifier of the document containing before and after.
before is the table object ID (toid) of the grid, column, or row after which the new grid, column, or row will be inserted.
after is the table object ID (toid) of the grid, column, or row before which the new grid, column, or row will be inserted.
op is the function callback operation. Callbacks are called twice in succession with op specifying the stage of callback operation.
1. op == 1 first call — The returned argument specifies whether the execution should continue or be stopped:
0 — Continue callback processing.
-1 — Stop further callback processing.
2. op == 2 second call — Occurs unless the processing was stopped during the first call. The returned argument allows or prevents basic Arbortext Editor processing after all callbacks have been called:
0 — Basic Arbortext Editor processing allowed.
-1 — Basic Arbortext Editor processing prevented.
Either the before or after arguments, but not both, may be h::tblNullToid if the new object will be inserted as the first or last grid, row, or column.