Пример #1
0
        private void BindEmolyeeList()
        {
            try
            {
                EWA_Common objEWA = new EWA_Common();
                BL_Common  objBL  = new BL_Common();

                objEWA.OrgId             = Convert.ToString(Session["OrgId"]);
                objEWA.DesignationId     = DDL_Designation.SelectedValue.ToString();
                objEWA.DepartmentId      = DDL_Department.SelectedValue.ToString();
                objEWA.DesignationTypeId = rbtnFacultyType.SelectedValue.ToString();

                DataSet ds = objBL.BindFacultyName(objEWA);


                DDL_EmoloyeeName.DataSource     = ds;
                DDL_EmoloyeeName.DataTextField  = "EmpName";
                DDL_EmoloyeeName.DataValueField = "UserCode";
                //ViewState["PayGrpID"] = "PayGrpID";
                DDL_EmoloyeeName.DataBind();
                DDL_EmoloyeeName.Items.Insert(0, "Select");
                DDL_EmoloyeeName.SelectedIndex = 0;
                DDL_EmoloyeeName.DataSource    = null;
                DDL_EmoloyeeName.DataBind();

                //if (ds.Tables[0].Rows[0]["PayGrpID"].ToString() != "")
                //{
                //    PayGroupID = Convert.ToInt32(ds.Tables[0].Rows[0]["PayGrpID"].ToString());
                //}
                //else
                //{
                //    PayGroupID = 0;
                //}
            }
            catch (Exception exp)
            {
                GeneralErr(exp.Message.ToString());
            }
        }