|
-
Jul 26th, 2005, 03:20 AM
#1
Thread Starter
Addicted Member
[RESOLVED] Delete from datagrid
I am currently trying to delete a row from the datagrid, so far so good until I tried to "acceptchanges" and keep on getting this error message:
"Update requires the DeleteCommand to have a Connection object. The Connection property of the DeleteCommand has not been initialized"
This is my code:
Try
Dim dt_BussLine As DataTable = Me.dg_BusLine.DataSource
dt_BussLine.Rows(dg_BusLine.CurrentRowIndex).Delete()
dadaptBusLine.Update(DsBusLine1)
Me.DsBusLine1.AcceptChanges()
Catch eexception As Exception
MsgBox(eexception.Message)
End Try
I don't understand what it means since I am currently connected to the table. Please Help!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|