string str2 = "select onedhname,onepic,ncontent,onedhid,state from main where twodhid=" + id + "and state="+t2+""; 论文网http://www.751com.cn/
SqlDataAdapter rst1 = new SqlDataAdapter(str2, cn);
DataSet rdt1 = new DataSet();
rst1.Fill(rdt1);
repeater1.DataSource = rdt1;
repeater1.DataBind();
string str3 = "select onedhname,state from main where onedhid=" + id + "and state=" + t2 + "";
SqlCommand cmd2 = new SqlCommand(str3, cn);
SqlDataReader mysdr = cmd2.ExecuteReader();
while (mysdr.Read())
{
Label8.Text = mysdr["onedhname"].ToString();
Label6.Text = mysdr["onedhname"].ToString();
}
cn.Close();
string id12 = Request.QueryString["id"] + "";
SqlConnection cn1 = new SqlConnection();
cn1.ConnectionString = "Data Source=127.0.0.1;Initial Catalog=Excellent courses;uid=sa;pwd=";论文网http://www.751com.cn/
cn1.Open();
string str1 = "select onedhname,onepic,ncontent,onedhid from main where twodhid=" + id12 + "order by onedhid desc";
SqlCommand cmd1 = new SqlCommand(str1, cn1);
SqlDataReader mysdr2 = cmd1.ExecuteReader();
while (mysdr2.Read())
{
Label4.Text = "<br>" + mysdr2["ncontent"].ToString();
Label5.Text = mysdr2["onedhname"].ToString();
Label7.Text = mysdr2["onedhname"].ToString();