Ejemplo n.º 1
0
        private void Add_Click(object sender, EventArgs e)
        {
            Navantazhennya = Navantazhennya ?? new Navantazhennya();

            Navantazhennya.DateTime   = dateTimePicker1.Value;
            Navantazhennya.Teacher    = (Teacher)comboBox1.SelectedItem;
            Navantazhennya.Month      = (string)comboBox2.SelectedItem;
            Navantazhennya.TypeNav    = (string)comboBox3.SelectedItem;
            Navantazhennya.QantityNav = Convert.ToInt32(textBox1.Text);
        }
Ejemplo n.º 2
0
        public InputNavantazhennyaForm(Navantazhennya navantazhennya) : this()
        {
            Navantazhennya = navantazhennya ?? new Navantazhennya();

            dateTimePicker1.Value  = Navantazhennya.DateTime;
            comboBox1.SelectedItem = Navantazhennya.Teacher;
            comboBox2.SelectedItem = Navantazhennya.Month;
            comboBox3.SelectedItem = Navantazhennya.TypeNav;
            textBox1.Text          = Convert.ToString(Navantazhennya.QantityNav);
        }