Ejemplo n.º 1
0
        private void CreateItem()
        {
            CarProducersEditView v = new CarProducersEditView();

            v._id = -1;
            v.ShowDialog();
        }
Ejemplo n.º 2
0
        private void EditSelectedItem()
        {
            int          id = 0;
            car_producer b  = null;

            if (dgList.SelectedItem != null)
            {
                object sel = dgList.SelectedItem;
                b  = (car_producer)sel;
                id = b.id;
            }
            if (id > 0)
            {
                CarProducersEditView v = new CarProducersEditView();
                v._id           = b.id;
                v.edtName.Text  = b.name;
                v.edtDescr.Text = b.descripton;
                v.ShowDialog();
                ReloadList();
            }
        }
Ejemplo n.º 3
0
 private void EditSelectedItem()
 {
     int id = 0;
     car_producer b = null;
     if (dgList.SelectedItem != null)
     {
         object sel = dgList.SelectedItem;
         b = (car_producer)sel;
         id = b.id;
     }
     if (id > 0)
     {
         CarProducersEditView v = new CarProducersEditView();
         v._id = b.id;
         v.edtName.Text = b.name;
         v.edtDescr.Text = b.descripton;
         v.ShowDialog();
         ReloadList();
     }
 }
Ejemplo n.º 4
0
 private void CreateItem()
 {
     CarProducersEditView v = new CarProducersEditView();
     v._id = -1;
     v.ShowDialog();
 }