コード例 #1
0
        private void Button6_Click(object sender, EventArgs e)
        {
            DrugForm InsertForm = new DrugForm();

            InsertForm.ShowDialog(this);
            LoadData();
        }
コード例 #2
0
 private void DataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
 {
     if (drugsGridView.SelectedRows.Count > 0)
     {
         DataGridViewRow selectedRow  = drugsGridView.SelectedRows[0];
         Drug            selectedItem = (Drug)selectedRow.DataBoundItem;
         DrugForm        InsertForm   = new DrugForm(selectedItem);
         InsertForm.label10.Text = "Змінити";
         InsertForm.ShowDialog(this);
         LoadData();
     }
 }