I have set the requisite attributes in the Grid View tag.
(Note, in the gridview the Enable View State="False" - if I set it to True I get the standard "Failed to load viewstate. error) One strange thing that I've noticed that makes me think it's a View State problem is that if I change the Command Name of the Update button to "Edit" that postback event does get captured in the Row Command event...
One has it's Command Name = "Update" and the other "Cancel".
My problem lies in that the click on the Update Image Button posts back, but neither the Row Command nor Row Updating events get triggered.
Find Control("txt CINVNUM"), Text Box) Dim last As Text Box = Direct Cast(row.
Find Control("txt Last"), Text Box) Dim drplist As Drop Down List = Direct Cast(row.
This works as expected and I can put a breakpoint in the Row Command event handler to see the "Event" command name.
After it has been clicked the postback places that row in edit mode. At this point in time the above Edit Item Template is displayed with two Image Buttons within it.
Row Updating Dim row As Grid View Row = Direct Cast(grv Sample. Row Index), Grid View Row) Dim passport Number As Text Box = Direct Cast(row.
Find Control("txt Name"), Text Box) Dim cinvnum As Text Box = Direct Cast(row.
I need to do the updating operation on what row is clicked.
" Select Command="SELECT a.tenantcode, a.name, a.fixedrate, a.percentrate, a.percentage, b.locationd, c.status FROM TENANTNEW AS a INNER JOIN LOCATION AS b ON a.
I am using a Template Field to display my Edit, Update and Cancel 'buttons' in the first column of the Grid View within respective Item Template and Edit Item Template fields.