Private Sub UltraGrid1_BeforeRowsDeleted( _
ByVal sender As System.Object, _
ByVal e As BeforeRowsDeletedEventArgs) _
Handles UltraGrid1.BeforeRowsDeleted
e.DisplayPromptMsg = True
Dim tmp as Integer = e.Rows.Length - 1
For i As Integer = 0 To tmp
Dim c As Customer = _
DirectCast(e.Rows(0).ListObject, Customer)
c.Delete()
Next
DataManager.UpdateAll()
End Sub