I have a grid "ugQtrSales". To allow for only 4 rows I want to cancel the add new row action if rowcount is greater than 4. I know the escape key (twice) cancels the add row action. What command(s) do I use and how would it look if I wanted to simulate that (pressing escape twice) or accomplish same thing, using code (VB).
You can prevent a row form being added by canceling the BeforeRowInsert event.
To simulate the action of canceling an edit mode session and then the modification of a row:
Me.ultraGrid.PerformAction(UltraGridAction.UndoCell)Me.ultraGrid.PerformAction(UltraGridAction.UndoRow)
Thank You
The UndoCell and UndoRow did the trick