ASP.NET C# - do you need a separate datasource for each gridview? [closed]
- by Brian McCarthy
Do you need a separate datasource for each gridview if each gridview is accessing the same database but different tables in the database? 
I'm getting an error on AppSettings that says non-invocable member. 
What is the problem with it? 
Here's the c# code-behind: 
        protected void Search_Zip_Plan_Age_Button_Click(object sender, EventArgs e)
        {
        var _with1 = this.ZipPlan_SqlDataSource;
        _with1.SelectParameters.Clear();
        _with1.ConnectionString = System.Configuration.ConfigurationManager.AppSettings("PriceFinderConnectionString").ToString;
        _with1.SelectCommand = "ssp_get_zipcode_plan";
        _with1.SelectParameters.Add("ZipCode", this.ZipCode.Text);
        _with1.SelectParameters.Add("PlanCode", this.PlanCode.Text);
        _with1.SelectParameters.Add("Age", this.Age.Text);        
        _with1.SelectCommandType = SqlDataSourceCommandType.StoredProcedure;
        _with1.CancelSelectOnNullParameter = false;
        Search_Results_GridView.DataBind();
        }
thanks!