We also need force databinding to occur when then page is loaded, which we’ll handle in Page_Load.The required actions for paging to work are setting the new page index, setting the Data Source, and calling Data Bind (the last two through the Bind Data method).We’re using Linq to SQL to pull data from our database and bind it to the Grid View.We’ll revisit this method when we implement the sorting functionality.The Grid View 'Grid View1' fired event Sorting which wasn't handled.The Grid View 'Grid View1' fired event Row Deleting which wasn't handled. When I say manually databinding I mean not using a data source control specified as a Data Source ID, but rather setting the Grid View’s Data Source equal to the appropriate data object and calling Data Bind. NET 2.0 are familiar with how to deal with this, but since ASP.The Statement Type enumeration defines Select, Insert, Update, and Delete members.
Listing 9-3 shows the code for the Fill Error event handler.
The Row Updating event occurs when an Update method is called before a command executed against the data source.
The Row Updated event occurs when a command executed.
After that I changed the button's name property to Data Adapter Events Test Btn and wrote a button-click event handler by double-clicking on the button control.
Next, I added a data adapter control to the form by dragging the Ole Bbd Ataadapter component from the toolbox's data tab to the form.