Rowupdating vs rowediting

aspdotnet-suresh offers C#articles and tutorials,csharp dot net,articles and tutorials, VB.I have a gridview which consists of 3 columns of dropdownlist, which these 3 dropdownlist are inter-related, means the 2nd dropdownlist will depends on the 1st dropdown value, where the 3rd dropdownlist will depends on the 2nd dropwdown value.While the Row Data Bound is Fired Everytime a Row is Bound, Meaning it will Be Fired More Than Once.

Have you tried setting the values when the gridview row command event is called?I'm having recurring problems with VS 2015 where my code behind pages seem to lose their relationship with their associated aspx page. Here's an example: In this example, the cs file gives me the following error on lbl ID.The only way I've found to deal with this so far is to trash the entire solution file, create a new one, copy the old code into it, and start over. Text in the Sql Data Reader: The name 'lbl ID' does not exist in the current context. If I trash my solution file, and create a brand new one, it will work. There are similar questions on Stackoverflow and other websites, but I seem to miss something.I have a Grid View bound to a Data Table which comes from a database.

To cancel the update operation, set the collections, if necessary, before the values are passed to the data source.

Please or register to post comments
If spammers comment on your content, only you can see and manage such comments Delete all
Hi, appreciate your feedback. When using aspButtonField, the only properties I have is CommandName. also by default, the ButtonField once clicked it fires Gridview. 
09-Oct-2018 23:20
RowUpdating fires before update command is excuted on data source. RowEditing is fired when edit event is generated on girdview. hope this helps 
09-Oct-2018 23:23
Gridview RowUpdating event not firing. but neither the RowCommand nor RowUpdating events get triggered. I have set the requisite attributes in the GridView tag. 
09-Oct-2018 23:26

Rowupdating vs rowediting introduction

Rowupdating vs rowediting