Esempio n. 1
0
        private void btnUredi_Click(object sender, EventArgs e)
        {
            List <int>   selektaniPutniNalozi = SelectPuntiNalozi();
            DialogResult potvrda = DialogResult.Cancel;

            if (selektaniPutniNalozi.Count == 1)
            {
                PutniNalogForm pn = new PutniNalogForm(this, selektaniPutniNalozi.First());
                pn.Show();
            }
            else if (selektaniPutniNalozi.Count > 1)
            {
                potvrda = MessageBox.Show($"Želiš li urediti odabrane naloge?"
                                          , "POTVRDI UREDJIVANJE"
                                          , MessageBoxButtons.OKCancel
                                          , MessageBoxIcon.Warning);
                if (potvrda == DialogResult.OK)
                {
                    foreach (int item in selektaniPutniNalozi)
                    {
                        PutniNalogForm pn = new PutniNalogForm(this, item);
                        pn.Show();
                    }
                }
            }
            else
            {
                MessageBox.Show($"Nisi odabrao niti jedan nalog");
            }
        }
Esempio n. 2
0
        private void btnAddPN_Click(object sender, EventArgs e)
        {
            PutniNalogForm pn = new PutniNalogForm(this, null);

            pn.Show();
        }