Daniel,
I added a button and defined an Event Handler ;
Note that I've used the row as (GetRowCount less 1)
(DEFUN c:DwgProp_FormDwp_SelectCurrentRow_OnClicked (/)
(ALERT (ITOA (ODCL_GRID_GETROWCOUNT DwgProp_FormDwp_GridProp)))
(ODCL_GRID_SELCURROW
DwgProp_FormDwp_GridProp
(- (ODCL_GRID_GETROWCOUNT DwgProp_FormDwp_GridProp) 1)
)
)
.. and changing the offending line in c:DwgProp_FormDwp_ButtonAddItem_OnClicked seems to work
;;(ODCL_GRID_SELCURROW DwgProp_FormDwp_GridProp (1+ nRow))
;<- Bug? <<<<<<<<
(ODCL_GRID_SELCURROW DwgProp_FormDwp_GridProp nRow)
added:So the issue is that the row count is Zero based , { I think }
PS added:
BTW, nice code