1

如何使用 ADO.NET C# 通过未绑定控件填充表格/网格。

    using (SqlConnection Connection = new SqlConnection())
    {
        Connection.ConnectionString = ConnectionString;
        Connection.Open();

        SqlDataAdapter Adapter = new SqlDataAdapter(Query + ItemIndex, Connection);
        DataSet DataSet = new DataSet();

        Adapter.Fill(DataSet);
        unbndgrdRecord.DataSource = DataSet;
        unbndgrdRecord.DataBind();
    }

这是我想在未绑定控制中转换它的代码...

4

0 回答 0