I have a problem when validating the data on records that are to be inserted into the grid.
The grid is just using the default insert item button on the grid with some template columns, some bound columns and some dateTimeColumns.
I am using the itemdatabound method to populate some dropdown controls in these template controls when the item is in edit mode.
When Insert command is called my code does some validation against the database and if this fails then it displays the failure message on the GridEditForm and sets the Canceled property of the GridCommandEventArgs to true.
This works fine however if I then click the button to Insert the record again and it fails again all of the controls are cleared losing all of their values.
Any help in working out why this is happening would be much appreciated.
Thanks
Gavin
The grid is just using the default insert item button on the grid with some template columns, some bound columns and some dateTimeColumns.
I am using the itemdatabound method to populate some dropdown controls in these template controls when the item is in edit mode.
When Insert command is called my code does some validation against the database and if this fails then it displays the failure message on the GridEditForm and sets the Canceled property of the GridCommandEventArgs to true.
This works fine however if I then click the button to Insert the record again and it fails again all of the controls are cleared losing all of their values.
Any help in working out why this is happening would be much appreciated.
Thanks
Gavin