Asp net gridview rowupdating newvalues empty

From some googling it appears that, at least in the release candidate for NET2 this was a known bug; only binding to Data Sources lets those dictionaries be populated. | | From some googling it appears that, at least in the release candidate for NET2 this was a known bug; only binding to Data Sources | lets those dictionaries be populated. 2) I think it's weird that the "value" capability is tied to the parameters collection. That way it'd work with both types of data binding. I would like to confirm that this is a problem with the released version of NET2, so I can stop beating my head against the wall trying to get the Grid View to work "as advertised". As for the Grid View control doesn't correctly populate the Old Values or New Values parameters collection when performing udpdate operation, I think it is likely caused by some certain setting in the Grid View control... | | I would like to confirm that this is a problem with the released version of NET2, so I can stop beating my head against the wall | trying to get the Grid View to work "as advertised". - Mark Thanks for your followup Mark, Frankly speeking, I do agree with you that this is a big limitation since I haven't noticed this before until you mentioned this... I ran into a situation this morning where the Row Updating event of a Grid View kept insisting there were no entries in either the Old Values or New Values dictionaries. not-for-mail | Xref: TK2MSFTNGXA02gbl microsoft.public.dotnet.framework.aspnet:372150 | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet | | I ran into a situation this morning where the Row Updating event of a Grid View kept insisting there were no entries in either the | Old Values or New Values dictionaries. Two things: 1) I think this needs to be documented better. | | 2) I think it's weird that the "value" capability is tied to the parameters collection. That | way it'd work with both types of data binding.The Grid View is bound to a strongly-typed collection, derived from Collection Base, through the control's datasource property at runtime. The Grid View is bound to a strongly-typed collection, derived from Collection Base, through the | control's datasource property at runtime. I don't recall seeing it emphasized in the documentation, and these kinds of dependencies create annoying bugs. not-for-mail | Xref: TK2MSFTNGXA02gbl microsoft.public.dotnet.framework.aspnet:372922 | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet | | Steven, | | Thanx for confirming the limitation.

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

If you reset the Data Source at this stage, your values for updating will be lost. I actually don't know how to write the Row Updating function, I just found it from the internet, and so of course it's not working. Please give some references and/or details of how to. Ok what's happening is that you are binding the data source for the Grid View every time a postback occurs in the Page_Load method.

Count ----------- The most common problem for losing new data entered while updating a Grid View or Data Grid is that you are resetting the Data Source for the Grid View or Data Grid in the Page_Load method. I actually don't know how to write the Row Updating function, I just found it from the internet, and so of course it's not working.

Please help me with writing a Row Updating function in C#, I don't know how to grab the current field's value and also get the old value for one of keys (which is Project Name for editing) of the selected row. the idea wa to don't allow binding the grid view after a post back.

hello my problem was that my gridview editable controls heep their old values. this is due to the grid view binding in the page_load method after every post back.

Leave a Reply