Q:

ASP.NET - Use a checkbox to change the results of a SqlDataSource

I'm using Visual Web Developer 2010 Express.  This is my first attempt at creating a .NET page.  I have a Gridview on a page that displays the results of a GridQuery.  This works.  I have a checkbox control (cb_Filter) on the same page that if checked, should add to the where clause of the GridQuery, (where Column5 IS NULL).  How do I check the state of the check box so it will run the query with or without the "filter". 

A:

really depends on your data access, if you have made a datasource on page, then you'll have two and the code will change which data source you have.  if it is using the old ado.net then you will have two commands that run in seperate methods that get the sql query, and a similar thing will work for linq.  Let me know how you bind to the grid and i will give you an example. 