DataBind and Postback
- by Michael La Voie
This is a general how does DataBind work questions...
I have a simple page with a GridView that is bound (in the aspx code) to an ObjectDataSource.
I can look in the Select() function called by the ObjectDataSource to see that it is called on the initial load and on every post back. I have some logic that happens on post backs that will affect the GridView's data, and I want to call GridView.DataBind() later on in the post back, after I've made some changes.
Is there a way to prevent the automatic rebinding that happens on each post back? Does this mean I can't use an ObjectDataSource for this control?