try this :
protected void Page_Load(object sender, EventArgs e)
{
string connection = "Data Source=path;Initial Catalog=commonlogin;User ID=sa;Password=; ";
SqlConnection conn = new SqlConnection(connection);
conn.Open();
SqlDataAdapter ad= new SqlDataAdapter("SELECT * FROM tbl_SqlImage", conn);
Dataset ds=new Dataset();
ad.fill(ds);
if(ds.tables[0].rows.count!=0)
{
Gridview1.Datasource=ds;
Gridview1.Databind();
}
Hope this will help you or if not Please the Post error which is generated.
Enjoy.