G
Greg
Hi - Newbie here.
Is there a way to reset the gridview so that I can continue to use the same
gridview and sqldatasource, but alter the SelectCommand to display different
data?
I have one gridview, and one SQLdatasource. Depending on where the user
clicks, I change the "SelectCommand" of the SQLDataSource to query a
different table in the same database. The data displays correctly, but when
I try to sort, I receive an error - one example is "Cannot find column
Name" - the Column Name is visible, but I think the problem is that the
gridview is 'remembering' the schema of the first SelectCommand used to
display the query. Sorting works for me for the first grid that's displayed,
but for all others (because I change the SelectCommand), sorting fails, but
data is displayed correctly.
Any help you can offer would be greatly appreciated.
Greg
Is there a way to reset the gridview so that I can continue to use the same
gridview and sqldatasource, but alter the SelectCommand to display different
data?
I have one gridview, and one SQLdatasource. Depending on where the user
clicks, I change the "SelectCommand" of the SQLDataSource to query a
different table in the same database. The data displays correctly, but when
I try to sort, I receive an error - one example is "Cannot find column
Name" - the Column Name is visible, but I think the problem is that the
gridview is 'remembering' the schema of the first SelectCommand used to
display the query. Sorting works for me for the first grid that's displayed,
but for all others (because I change the SelectCommand), sorting fails, but
data is displayed correctly.
Any help you can offer would be greatly appreciated.
Greg