i add the handling function manually as such
where dg is a datagrid and dg has a editcommandcolumn
(all my datagrids are dynamically created)
AddHandler dg.EditCommand, AddressOf Grid_EditCommand
AddHandler dg.UpdateCommand, AddressOf Grid_UpdateCommand
AddHandler dg.CancelCommand, AddressOf Grid_CancelCommand
AddHandler dg.ItemCommand, AddressOf Grid_ItemCommand
I write a function
Private Sub Grid_UpdateCommand(ByVal source As System.Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
......
end sub
Private Sub Grid_EditCommand(ByVal source As System.Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
......
end sub
when i step through the code, the Grid_EditCommand gets called, when i press the edit button.
however, when i the press the update button, the Grid_UpdateCommand never gets called. rather, the Grid_editCommand gets called.
WHAT AM I DOING WRONG HERE?????
(neither the Grid_CancelCommand gets called)
where dg is a datagrid and dg has a editcommandcolumn
(all my datagrids are dynamically created)
AddHandler dg.EditCommand, AddressOf Grid_EditCommand
AddHandler dg.UpdateCommand, AddressOf Grid_UpdateCommand
AddHandler dg.CancelCommand, AddressOf Grid_CancelCommand
AddHandler dg.ItemCommand, AddressOf Grid_ItemCommand
I write a function
Private Sub Grid_UpdateCommand(ByVal source As System.Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
......
end sub
Private Sub Grid_EditCommand(ByVal source As System.Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
......
end sub
when i step through the code, the Grid_EditCommand gets called, when i press the edit button.
however, when i the press the update button, the Grid_UpdateCommand never gets called. rather, the Grid_editCommand gets called.
WHAT AM I DOING WRONG HERE?????
(neither the Grid_CancelCommand gets called)