Gridview population

I look at this code all weekend. I know that there is data, and I can pull it through other requests, but the GridView will not be displayed and filled. Suggestions?

        string sqlSelection =
                    "SELECT * FROM [COMPANY].[dbo].[parking] ";

        SqlConnection cn = new SqlConnection(ConfigurationManager.ConnectionStrings["DATACONNECTION"].ToString());
        //This connection works in MSSMS and in other pages I have on the same server

        SqlDataAdapter sda = new SqlDataAdapter(sqlSelection, cn);

        SqlCommandBuilder scb = new SqlCommandBuilder(sda);

        DataTable dTable = new DataTable();

        sda.Fill(dTable);
            //debug shows: dTable <not set>


        GrdDynamic.Visible = true;
        GrdDynamic.DataSource = dTable;
        GrdDynamic.DataBind();
+3
source share
1 answer

, , - . ( sql), sql ( ) db. , , ( , ). , - SQL- - . , ping sql. - . , , .

0
source

All Articles