private void buttonIzmeni_Click(object sender, EventArgs e) { Procedura p = new Procedura(); p.ucitaj(listBoxProcedure.SelectedItem.ToString()); Optuznica o = new Optuznica(); o.ucitaj(p.OptuznicaId); o.Text = richTextBoxPromenaOptuznice.Text; o.azuriraj(); }
private void listBoxProcedure_SelectedIndexChanged(object sender, EventArgs e) { if (listBoxProcedure.SelectedIndex >= 0) { Procedura p = new Procedura(); p.ucitaj(listBoxProcedure.SelectedItem.ToString()); Optuznica o = new Optuznica(); o.ucitaj(p.OptuznicaId); richTextBoxPromenaOptuznice.Text = o.Text; } }
private void listBoxProcedure_SelectedIndexChanged(object sender, EventArgs e) { if (listBoxProcedure.SelectedIndex >= 0) { Procedura p = new Procedura(); p.ucitaj(listBoxProcedure.SelectedItem.ToString()); textBoxNovoImeSuda.Text = p.ImeSuda; textBoxImeSudjije.Text = p.ImeSudije; Optuznica opt = new Optuznica(); opt.ucitaj(p.OptuznicaId); richTextBoxOpt.Text = opt.Text; this.otvoriKaznu(); } else { MessageBox.Show("Morate selektovati nesto."); } }