Click to See Complete Forum and Search --> : Datagrid: Adding a new row and then canceling


gknierim
February 18th, 2000, 07:55 AM
I am using a datagrid and this is my problem. When I click on the add button to add a new row to the grid and then click on the Close button to close the form, I receive an error stating that I "cannot insert an empty row - must have at least one column value set." I am using the cancelupdate method but this only works if there have been fields that were modified. I can hard code some garbage string in the key and then the CancelUpdate method works fine. Is there a way to delete the blank row after adding it in a datagrid?

gknierim
February 18th, 2000, 11:00 AM
Don't answer this...I figured it out!

RH+
March 29th, 2006, 09:25 PM
im having this problem now...how can i solve it?
i use addnew, and the press cancelupdate and i have that same error: "cannot insert an empty row - must have at least one column value set."
im using a dataenvironment with a datagrid
thanks