Hi ,
Just change statement according to your Query as long you are using Bind expression just Give to Grid Data soure .
void Getdata()
{
SqlConnection con = new SqlConnection(@"Data Source=.;Initial Catalog=test;Integrated Security=True");
string statement = "select item_code, Item_name, brand, size, section, price, Material, Qty, tax, tt from Items ";
SqlDataAdapter da = new SqlDataAdapter(statement, con);
DataSet ds = new DataSet();
da.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
}
Best Regards
M.Mitwalli