Esempio n. 1
0
 /// <summary>
 /// To fill rack combobox
 /// </summary>
 public void RackComboFill()
 {
     try
     {
         RackSP    spRack = new RackSP();
         DataTable dtbl   = new DataTable();
         dtbl = spRack.RackViewAll();
         DataRow dr = dtbl.NewRow();
         dr["rackName"] = "All";
         dr["rackId"]   = 0;
         dtbl.Rows.InsertAt(dr, 0);
         cmbRack.DataSource    = dtbl;
         cmbRack.DisplayMember = "rackName";
         cmbRack.ValueMember   = "rackId";
     }
     catch (Exception ex)
     {
         formMDI.infoError.ErrorString = "SER7:" + ex.Message;
     }
 }
Esempio n. 2
0
 /// <summary>
 /// Function to fill rack combobox
 /// </summary>
 public void RackComboFill()
 {
     try
     {
         RackSP    spRack = new RackSP();
         DataTable dtbl   = new DataTable();
         dtbl = spRack.RackViewAll();
         DataRow dr = dtbl.NewRow();
         dr["rackName"] = "All";
         dr["rackId"]   = 0;
         dtbl.Rows.InsertAt(dr, 0);
         cmbRack.DataSource    = dtbl;
         cmbRack.DisplayMember = "rackName";
         cmbRack.ValueMember   = "rackId";
     }
     catch (Exception ex)
     {
         MessageBox.Show("SE:10" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Esempio n. 3
0
        /// <summary>
        /// Function to view all rack combobox in grid
        /// </summary>
        public void RackGridComboFill()
        {

            try
            {
                DataTable dtbl = new DataTable();
                RackSP spRack = new RackSP();
                dtbl = spRack.RackViewAll();
                DataRow drow = dtbl.NewRow();
                drow["rackName"] = string.Empty;
                drow["rackId"] = 0;
                dtbl.Rows.InsertAt(drow, 0);
                dgvcmbrack.DataSource = dtbl;
                dgvcmbrack.DisplayMember = "rackName";
                dgvcmbrack.ValueMember = "rackId";
            }
            catch (Exception ex)
            {
                MessageBox.Show("PC:55" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }
Esempio n. 4
0
 /// <summary>
 /// Function to fill DataGridView Rack  combobox 
 /// </summary>
 public void DGVRackComboFill()
 {
     try
     {
         RackSP spRack = new RackSP();
         DataTable dtblRack = new DataTable();
         dtblRack = spRack.RackViewAll();
         dgvcmbRack.DataSource = dtblRack;
         dgvcmbRack.ValueMember = "rackId";
         dgvcmbRack.DisplayMember = "rackName";
     }
     catch (Exception ex)
     {
         MessageBox.Show("PR:09" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
Esempio n. 5
0
 /// <summary>
 /// Function to fill rack combobox
 /// </summary>
 public void RackComboFill()
 {
     try
     {
         RackSP spRack = new RackSP();
         DataTable dtbl = new DataTable();
         dtbl = spRack.RackViewAll();
         DataRow dr = dtbl.NewRow();
         dr["rackName"] = "All";
         dr["rackId"] = 0;
         dtbl.Rows.InsertAt(dr, 0);
         cmbRack.DataSource = dtbl;
         cmbRack.DisplayMember = "rackName";
         cmbRack.ValueMember = "rackId";
     }
     catch (Exception ex)
     {
         MessageBox.Show("SE:10" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }
 /// <summary>
 /// Function to fill Rack combobox
 /// </summary>
 public void RackComboFill()
 {
     try
     {
         RackSP spRack = new RackSP();
         DataTable dtblRack = new DataTable();
         dtblRack = spRack.RackViewAll();
         cmbRack.DataSource = dtblRack;
         cmbRack.ValueMember = "rackId";
         cmbRack.DisplayMember = "rackName";
         SettingsSP spSettings = new SettingsSP();
         if (spSettings.SettingsStatusCheck("AllowRack") == "Yes")
         {
             cmbRack.Enabled = true;
         }
         else
         {
             cmbRack.Enabled = false;
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("MPC9:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
     }
 }