Esempio n. 1
0
        private void lstIspiti_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (lstIspiti.SelectedIndex != -1)
            {
                btnIzbrisiIspit.Enabled = true;
                Ispit ispit = lstIspiti.SelectedItem as Ispit;
                txtOpis1.Text = ispit.Zadaca1.Description;
                txtOpis2.Text = ispit.Zadaca2.Description;

                nudPoeni1.Value = ispit.Zadaca1.Points;
                nudPoeni2.Value = ispit.Zadaca2.Points;
            }
        }
Esempio n. 2
0
 private void btnSave2_Click(object sender, EventArgs e)
 {
     if (lstIspiti.SelectedIndex != -1)
     {
         Ispit ispit = lstIspiti.SelectedItem as Ispit;
         ispit.Zadaca2.Description = txtOpis2.Text;
         ispit.Zadaca2.Points      = Convert.ToInt32(nudPoeni2.Value);
     }
     else
     {
         string message = "Изберете испит!";
         string caption = "Грешка при зачувување";
         MessageBox.Show(message, caption, MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Esempio n. 3
0
        private void Form1_Load(object sender, EventArgs e)
        {
            Ispit ispit1 = new Ispit();

            ispit1.Year  = 2017;
            ispit1.Month = "Јуни";

            Ispit ispit2 = new Ispit();

            ispit2.Year  = 2018;
            ispit2.Month = "Јуни";

            lstIspiti.Items.Add(ispit1);
            lstIspiti.Items.Add(ispit2);
        }
Esempio n. 4
0
 public DodadiIspit()
 {
     InitializeComponent();
     Ispit = new Ispit();
 }