Example #1
0
 private void addToolStripMenuItem_Click(object sender, EventArgs e)
 {
     using (AddEditCategory frm = new AddEditCategory(null))
     {
         if (frm.ShowDialog() == System.Windows.Forms.DialogResult.OK)
         {
             LoadCategories();
             categoryBindingSource.MoveLast();
         }
     }
 }
Example #2
0
        private void metroGrid1_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            Category obj = categoryBindingSource.Current as Category;

            using (AddEditCategory frm = new AddEditCategory(obj))
            {
                if (frm.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                {
                    LoadCategories();
                }
            }
        }