Hello
I am getting a CS1502: The best overloaded method match for 'System.Data.Sq lClient.SqlData Adapter.SqlData Adapter(System. Data.SqlClient. SqlCommand)' has some invalid arguments
I have no idea what I've done wrong!
Thank you
Dave
I am getting a CS1502: The best overloaded method match for 'System.Data.Sq lClient.SqlData Adapter.SqlData Adapter(System. Data.SqlClient. SqlCommand)' has some invalid arguments
I have no idea what I've done wrong!
Code:
string strConn = ConfigurationManager.ConnectionStrings["BoardToBoard"].ConnectionString;
string strB2BSQL = "SELECT * FROM View_BoardToBoard";
SqlConnection B2BConn;
DataSet ds = new DataSet();
SqlDataAdapter B2BDA;
B2BConn = new SqlConnection(strConn);
B2BDA = new SqlDataAdapter(strB2BSQL);
try
{
B2BConn.Open();
B2BDA.Fill(ds, "B2B");
grdB2B.DataSource = ds;
grdB2B.DataBind();
}
finally
{
B2BConn.Close();
}
Dave
Comment