Esempio n. 1
0
        // Bind Department BindDepartment_BL

        #region [Bind DeviceSettings]

        public DataSet BindAttDevices_BL(EWA_DownloadAttDeviceData objEWA)
        {
            try
            {
                DL_DownloadAttDeviceData objDL = new DL_DownloadAttDeviceData();
                DataSet ds = objDL.BindAttDevices_DL(objEWA);
                return(ds);
            }
            catch (Exception)
            {
                throw;
            }
        }
        //Bind Devices
        #region [Bind Devices]

        private void BindDevices()
        {
            try
            {
                EWA_DownloadAttDeviceData objEWA = new EWA_DownloadAttDeviceData();
                BL_DownloadAttDeviceData  objBL  = new BL_DownloadAttDeviceData();
                objEWA.OrgId = "1";
                DataSet dsDesignation = objBL.BindAttDevices_BL(objEWA);
                ddlDeviceName.DataSource     = dsDesignation;
                ddlDeviceName.DataTextField  = "DeviceName";
                ddlDeviceName.DataValueField = "DeviceSettingId";

                ddlDeviceName.DataBind();
                ddlDeviceName.Items.Insert(0, "Select");
            }
            catch (Exception exp)
            {
                GeneralErr(exp.Message.ToString());
            }
        }
        // Bind Departments BindDepartment

        #region Bind AttDevices

        public DataSet BindAttDevices_DL(EWA_DownloadAttDeviceData objEWA)
        {
            DataSet ds = null;

            try
            {
                prmList    = new string[4];
                prmList[0] = "@Action";
                prmList[1] = "FetchAttDevices";
                prmList[2] = "@OrgId";
                prmList[3] = objEWA.OrgId;

                ds = ObjHelper.FillControl(prmList, "SP_DownloadAttDeviceData ");
                if (ds.Tables[0].Rows.Count > 0)
                {
                    return(ds);
                }
            }
            catch (Exception)
            {
                throw;
            }
            return(ds);
        }