i have to show data in datagrid view in windows forms
for that write code in class library as
public DataSet fillgrid()
{
string selectall = "select * from employee";
con.Open();
da = new SqlDataAdapter(selectall,con);
da.Fill(ds,"employee");
//con.Close();
return ds;
}
and iload add reference
and write code on form load as
Class1 c1 = new Class1();
dataGridView1.DataSource = c1.fillgrid().Tables[0];
my problem is datagrid view is not showing table