private void Teacher_Fill()
        {
            Teacher_Bussiness Obj_Teacher = new Teacher_Bussiness();
            List <Teacher>    Obj_Teach   = Obj_Teacher.GetTeachers();

            if (Obj_Teach != null && Obj_Teach.Count > 0)
            {
                grd.DataSource = Obj_Teach;
                grd.DataBind();
            }
            else
            {
                grd.DataSource = null;
                grd.DataBind();
            }
        }
Ejemplo n.º 2
0
        private void TeacherFill()
        {
            Teacher_Bussiness Obj_Teach      = new Teacher_Bussiness();
            List <Teacher>    Obj_Teacher_ID = Obj_Teach.GetTeachers();

            if (Obj_Teacher_ID != null && Obj_Teacher_ID.Count > 0)
            {
                for (int i = 0; i < Obj_Teacher_ID.Count; i++)
                {
                    ddl_Teacher.Items.Add(Obj_Teacher_ID[i].ID.ToString());
                }
                ddl_Teacher.Items.Insert(0, new ListItem("Select Teacher", " "));
            }
            else
            {
                ddl_Teacher.Items.Clear();
            }
        }