Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
pitt1
Starting Member
16 Posts |
Posted - 2006-07-09 : 07:07:18
|
Hello all,I'm reading a tutorial about updating an sql table using ado.net capabilities, in this example, using a data grid to get input values and update the needed row in the table, now, the problem is thati don't really understand what is the content of the "UpdateView()" function, i've tried several things but don't really achieve the thing updateView() need’s to do (just updating the view, after the :"grid.EditItemIndex = e.Item.ItemIndex;")if anyone can helps..Best,P.public void EditCommand(Object sender, DataGridCommandEventArgs e) { // Set the current item to edit mode grid.EditItemIndex = e.Item.ItemIndex; // Refresh the grid UpdateView();}public void UpdateCommand(Object sender, DataGridCommandEventArgs e) { // TODO: Retrieve new text and update the data source // Reset the edit mode for the current item grid.EditItemIndex = -1; // Refresh the grid UpdateView();} public void CancelCommand(Object sender, DataGridCommandEventArgs e) { // Reset the edit mode for the current item grid.EditItemIndex = -1; // Refresh the grid UpdateView();} |
|
|
|
|