示例#1
0
        private void metroTile5_Click(object sender, EventArgs e)
        {
            all_invent a = new all_invent();

            a.metroLabel7.Text = "sold";
            a.Text             = "SOLD OUT INVENTORY DETAILS";
            a.Visible          = true;
            //a.metroButton1.PerformClick();
        }
示例#2
0
        private void metroTile1_Click(object sender, EventArgs e)
        {
            all_invent a = new all_invent();

            a.metroLabel7.Text = "available";
            a.Text             = "AVAILABLE INVENTORY DETAILS";
            a.Visible          = true;

            //a.metroLabel1.Text = "all";
            //a.Text = "ALL STOCK DETAILS";
            //a.metroButton1.PerformClick();
        }
示例#3
0
        private void metroTile17_Click(object sender, EventArgs e)
        {
/*            Buyer_List b = new Buyer_List();
 *          b.Visible = true;
 *          b.Text = "BUYER LIST";
 *          b.metroLabel1.Text = "B";
 *          b.metroButton1.PerformClick();*/

            all_invent a = new all_invent();

            a.metroLabel7.Text = "all";
            a.Text             = "ALL INVENTORY DETAILS";
            a.Visible          = true;
        }
示例#4
0
        private void metroButton1_Click(object sender, EventArgs e)
        {
            /*metroGrid1.Rows.Clear();
             * metroGrid1.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCells;
             * metroGrid1.DefaultCellStyle.WrapMode = DataGridViewTriState.True;
             * int sele = 0;
             * String q1 = "";
             * if (metroLabel7.Text.ToString().Equals("all"))
             * {
             *  q1 = "Select * from stone;";
             *  sele = 1;
             * }
             * else if (metroLabel7.Text.ToString() == "available")
             * {
             *  q1 = "Select * from stone where c_pcs>0 and c_qty>0;";//order by date_in;";
             *  sele = 2;
             * }
             * else if (metroLabel7.Text == "sold")
             * {
             *  q1 = "Select * from stone where c_pcs=0 and c_qty=0;";//order by date_in;";
             *  sele = 4;
             * }
             *
             * foreach (DataGridViewColumn col in metroGrid1.Columns)
             * {
             *  //col.HeaderCell.Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
             *  col.DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
             *  col.DefaultCellStyle.Font = new System.Drawing.Font("Arial", 12F, FontStyle.Bold, GraphicsUnit.Pixel);
             * }
             * int row = 0;
             * String s1 = "";
             * int count = 1;
             *
             * MySqlConnection con1 = new MySqlConnection("SERVER=localhost;DATABASE=SilverCity;UID=root;PASSWORD=smhs; Connection Timeout=30; Min Pool Size=20; Max Pool Size=300;");
             * MySqlCommand cmd1 = new MySqlCommand(q1, con1);
             * MySqlDataReader dataReader1;
             * con1.Open();
             * dataReader1 = cmd1.ExecuteReader();
             * double namt = 0, nbrok = 0, wtt = 0;
             * int index = 0;
             * double t_pcs = 0, t_qty = 0, t_amt = 0, p_pcs = 0, p_qty = 0, p_amt = 0;
             * //Task.Factory.StartNew(() =>
             * //{
             *  while (dataReader1.Read())
             *  {
             *      if (index != 0)
             *          index = this.metroGrid1.Rows.Count;
             *
             *      index++;
             *
             *      this.metroGrid1.Rows.Add();
             *
             *      (metroGrid1.Rows[row].Cells[0]).Value = count;
             *      int lt1 = Convert.ToInt32(dataReader1.GetValue(0));
             *      if (lt1 != 103 && lt1 != 866)
             *          (metroGrid1.Rows[row].Cells[1]).Value = lt1;
             *      else
             *          (metroGrid1.Rows[row].Cells[1]).Value = dataReader1.GetValue(0);
             *      s1 = dataReader1.GetValue(1).ToString();
             *      DateTime d = Convert.ToDateTime(s1);
             *      (metroGrid1.Rows[row].Cells[2]).Value = d.ToShortDateString();
             *      (metroGrid1.Rows[row].Cells[3]).Value = dataReader1.GetValue(2);
             *      (metroGrid1.Rows[row].Cells[4]).Value = dataReader1.GetValue(3);
             *      (metroGrid1.Rows[row].Cells[5]).Value = dataReader1.GetValue(4);
             *      (metroGrid1.Rows[row].Cells[6]).Value = dataReader1.GetValue(5);
             *      t_pcs = t_pcs + Convert.ToDouble(dataReader1.GetValue(6));
             *      t_qty = t_qty + Convert.ToDouble(dataReader1.GetValue(7));
             *      p_pcs = p_pcs + Convert.ToDouble(dataReader1.GetValue(9));
             *      p_qty = p_qty + Convert.ToDouble(dataReader1.GetValue(10));
             *      t_amt += Convert.ToDouble(dataReader1.GetValue(15));
             *      p_amt += Convert.ToDouble(dataReader1.GetValue(16));
             *      (metroGrid1.Rows[row].Cells[7]).Value = Convert.ToDouble(dataReader1.GetValue(6));
             *      (metroGrid1.Rows[row].Cells[8]).Value = Convert.ToDouble(dataReader1.GetValue(7));
             *      (metroGrid1.Rows[row].Cells[9]).Value = dataReader1.GetValue(8);
             *      (metroGrid1.Rows[row].Cells[10]).Value = Convert.ToDouble(dataReader1.GetValue(9));
             *      (metroGrid1.Rows[row].Cells[11]).Value = Convert.ToDouble(dataReader1.GetValue(10));
             *      (metroGrid1.Rows[row].Cells[12]).Value = dataReader1.GetValue(11);
             *      (metroGrid1.Rows[row].Cells[13]).Value = dataReader1.GetValue(12);
             *      (metroGrid1.Rows[row].Cells[14]).Value = dataReader1.GetValue(13);
             *      (metroGrid1.Rows[row].Cells[15]).Value = dataReader1.GetValue(14);
             *      (metroGrid1.Rows[row].Cells[16]).Value = Convert.ToDouble(dataReader1.GetValue(15));
             *      (metroGrid1.Rows[row].Cells[17]).Value = Convert.ToDouble(dataReader1.GetValue(16));
             *      (metroGrid1.Rows[row].Cells[18]).Value = dataReader1.GetValue(17);
             *      (metroGrid1.Rows[row].Cells[19]).Value = dataReader1.GetValue(18);
             *      count++;
             *      row++;
             *  }
             * //});
             * //            metroLabel2.Text = "" + sele;
             * metroTextBox10.Text = "" + t_pcs;
             * metroTextBox8.Text = "" + t_qty;
             * metroTextBox9.Text = "" + t_amt;
             *
             * metroTextBox2.Text = "" + p_pcs;
             * metroTextBox3.Text = "" + p_amt;
             * metroTextBox7.Text = "" + p_qty;
             *
             * metroDateTime1.ResetText();
             * metroDateTime2.ResetText();
             *
             * metroTextBox1.Text = "";
             * metroTextBox4.Text = "";
             * metroTextBox5.Text = "";
             * metroTextBox6.Text = "";
             * metroComboBox1.SelectedIndex = -1;
             * metroComboBox2.SelectedIndex = -1;
             * metroComboBox3.SelectedIndex = -1;
             * metroComboBox4.SelectedIndex = -1;
             * metroComboBox5.SelectedIndex = -1;
             */
//            this.Refresh = true;
            all_invent ne = new all_invent();

            ne.Text             = this.Text;
            ne.metroLabel7.Text = this.metroLabel7.Text;
            ne.Visible          = true;
            this.Dispose();
        }