示例#1
0
 public void Myworking(Student_MyWorking work, SqlDataReader reader)
 {
     ((Label)work.FindControl("WorkName")).Text   = reader.GetString(2);
     ((Label)work.FindControl("WorkTime")).Text   = reader.GetString(3);
     ((Label)work.FindControl("WorkMoney")).Text  = reader.GetInt32(6).ToString();
     ((Label)work.FindControl("WorkPlace")).Text  = reader.GetString(4);
     ((Label)work.FindControl("WorkPeople")).Text = reader.GetInt32(5).ToString();
 }
示例#2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        SqlDataReader reader = DAL.ManagerDAL.SelectStuWorking(Session["account"].ToString());

        while (reader.Read())
        {
            Student_MyWorking working = (Student_MyWorking)LoadControl("MyWorking.ascx");
            working.Myworking(working, reader);

            Panel1.Controls.Add(working);
        }
    }