BradleyCleveland
asked on
refresh gridview in IFrame
Just for the record, I'm new to asp.net, so be specific.
I have a main page with an Iframe on it. On the IFrame page I have a gridview that is based on an sql query command. On the main page, I have a listbox with dates in it. What I need to happen is when the user selects a date from the listbox, the date value is sent as a parameter to the gridview on the IFrame so that the sql statement for the gridview is now based on the new date. If it would be better to move the Gridview to the main page, i don't have a problem with that as long as all my other controls on the page don't get refreshed.
I have a main page with an Iframe on it. On the IFrame page I have a gridview that is based on an sql query command. On the main page, I have a listbox with dates in it. What I need to happen is when the user selects a date from the listbox, the date value is sent as a parameter to the gridview on the IFrame so that the sql statement for the gridview is now based on the new date. If it would be better to move the Gridview to the main page, i don't have a problem with that as long as all my other controls on the page don't get refreshed.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You can use an Ajax update panel (instead of the iframe) to contain the gridview that is triggered by the list box.
For update panel check:
http://www.4guysfromrolla.com/articles/102407-1.aspx
http://www.dotnetfunda.com/tutorials/ajax/updatepanel.aspx
http://www.asp.net/ajax/tutorials/understanding-partial-page-updates-with-asp-net-ajax
For update panel check:
http://www.4guysfromrolla.com/articles/102407-1.aspx
http://www.dotnetfunda.com/tutorials/ajax/updatepanel.aspx
http://www.asp.net/ajax/tutorials/understanding-partial-page-updates-with-asp-net-ajax
ASKER
I was able to get the gridview back on the main page and refresh the data. I thought that it would affect the other controls when I refreshed it, but it didn't so I'm happy that I don't even have to deal with iFrames for now.
Are IFrames (HTML) obsolete?
http://stackoverflow.com/questions/755795/are-iframes-html-obsolete