فى page_load()
يوجد هذا الكود
if (!IsPostBack)
{
SqlConnection con1 = new SqlConnection("Password=asd;Persist Security Info=True;User ID=sa;Initial Catalog=hady_workshop;Data Source=NEWLOOK");
con1.Open();
SqlCommand cmd1 = new SqlCommand("select code from rate ", con1);
SqlDataReader dr1 = cmd1.ExecuteReader();
while (dr1.Read())
{
Label2.Text += "<li>" + dr1["code"];
//Label8.Text += "<li>" + dr["pdescription"];
}
con1.Close();
}[/code
]
وكود اخرررررررررررررررررررر
[code]SqlConnection con = new SqlConnection("Password=asd;Persist Security Info=True;User ID=sa;Initial Catalog=hady_workshop;Data Source=NEWLOOK");
con.Open();
SqlCommand cmd = new SqlCommand("select * from products",con);
SqlDataReader dr = cmd.ExecuteReader();
while (dr.Read())
{
Repeater1.DataSource = dr;
Repeater1.DataBind();
}دلوقتى فية
2connection string
ممكن يبقى فبة واحدة بس؟
هل ممكن يبقى فية connection string واحدة بس
واعملها inhretance?????????


