I have a search page that displays a gridview of results based on values entered into the form. What I would like to be able to do is have a button New Search. It would let me fill out the search criteria form again and on submit would add another grid view to the page with another result set. I want to be able to do it several times.
+1
A:
If what you're trying to do is to have more than one grid on the page at some point you just need to instantiate a new GridView set the properties including the DataSource and databind it. This has to be done behind the on click event of the new Search Event.
In order to achieve this you'll have to add the control to a parent panel.
parent.Controls.Add(dynamicGrid);
To add the ajaxy behavior you'll need to setup an update panel
Be careful not to abuse the update panel!
jgarcia
2009-07-07 04:07:20