Example #1
0
 public static Singleton_VarGlobal Instance()
 {
     if (data == null)
     {
         data = new Singleton_VarGlobal();
     }
     return(data);
 }
Example #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            DAL.Singleton_VarGlobal Var_Global = DAL.Singleton_VarGlobal.Instance();
            Var_Global.Global_id_p       = this.dataGridView1.CurrentRow.Cells[0].EditedFormattedValue.ToString();
            Var_Global.Global_name_p     = this.dataGridView1.CurrentRow.Cells[1].EditedFormattedValue.ToString();
            Var_Global.Global_category_p = this.dataGridView1.CurrentRow.Cells[2].EditedFormattedValue.ToString();
            Var_Global.Global_price_p    = this.dataGridView1.CurrentRow.Cells[3].EditedFormattedValue.ToString();
            Var_Global.Global_note_p     = this.dataGridView1.CurrentRow.Cells[4].EditedFormattedValue.ToString();
            Update newform = new Update();

            newform.ShowDialog();
            Select_Products();
        }