NET forum I visit is how to change SQLData Source parameter. I know two common solutions to this problem, though I only tried one in my own web-pages.
I want to provide my user a Gridview filled with data from database, allowing him to edit these records not in order to update the database, but in order to insert edited rows in db as new records through a stored procedure. - to use Edit built-in capabilities (Edit button, Edit Item Template etc.) because I don't need to make any real updating and I don't have a clear idea of how to "bypass" the parts I don't want.) Cri Thanks, yousuf... I think Edit Index is nothing, because the whole Edit thing is never raised.
Row Editing ds = Get Data() '// get your data here from database With gv Test .
not After), the new value is not used for the Update operation? The alternative I thought was to make the assigmment to the Total Plan column in the On Text Changed event of each Mth_1 and 2, but if I can write the assignment in a central place and only at a time before updating, it seems less messy and less frequent.
I put a stop in the I still dont know about why this doesnt work in the grid's Row Updating event, but the alternative solution I used was to do the assignment by subscribing to the On Updating event of the Sql Data Source and assigning as shown below. Your solution didn't work for me because the Update Parameters collection in my case has no parameters, so I can't assign a value that way.
:icon_rolleyes: I'll fight a little more on my own and I'll post the results.
I used your code in Row Editing event and gridview becomes editable, but I still have some trouble in accessing the Edit Template controls...Once you register for an account you will have immediate access to the forums and all past articles and commentaries. azure book business intelligence c# database excel gotcha how to mongodb nosql performance security sql sql advent 2012 sql friday sql server sql server 2000 sql server 2005 sql server 2008 sql server 2008 r2 sql server 2012 ssis ssms ssrs syndicated t-sql tip unit testing One of the often asked questions on ASP. Protected Sub gv Autorizzazioni_Row Command(By Val sender As Object, By Val e As System. So I have my Gridview with Data Source set to a Data Table on page Load event : In the Click event of the button I want to retrieve current values of the controls, as displayed on Web page after user's actions, and pass them to my sp as a comma-separated string. Is Null Or Empty(str Add) = False Then str Per Insert = str Per Insert & str Add & "," '..so on to add values to string What to do to retrieve edited values? I also tried setting Edit Index to the index of "pseudo-edited" row, just before your code: Thanks, yousuf... I think Edit Index is nothing, because the whole Edit thing is never raised. This is a sample of retrieving an output parameter’s value in Inserted event of SQLData Source Protected Sub Sql Data Source1_Inserted(By Val sender As Object, By Val e As System.