Exemplo n.º 1
0
    public Course(int courseID)
    {
        this.courseID = courseID;
        DataTable courseTB = AppData.GetCourseDetail(courseID);

        if (courseTB.Rows.Count > 0)
        {
            this.courseID      = courseID;
            this.courseName    = courseTB.Rows[0]["CourseName"].ToString();
            this.courseSession = courseTB.Rows[0]["CourseSession"].ToString();
            this.courseOwner   = courseTB.Rows[0]["courseOwner"].ToString();
            this.available     = courseTB.Rows[0]["Active"].ToString();
            this.chapterCount  = Chapter.ChapterCount(courseID).ToString();
        }
    }