private void dodajTipVrsteToolStripMenuItem_Click(object sender, EventArgs e) { FormTip tip = new FormTip(this); DialogResult r = tip.ShowDialog(); refreshTree(); }
private void toolStripMenuItem3_Click(object sender, EventArgs e) { //dodavanje tipa FormTip tip = new FormTip(this); DialogResult r = tip.ShowDialog(); refreshTree(); }
private void timerDemo_Tick(object sender, EventArgs e) { timerDemo.Stop(); if (demoMode) { otvorenDijalog = new FormTip(this); otvorenDijalog.Show(); timerUnesTipa.Start(); } }
private void izmjenimenit_Click(object sender, EventArgs e) { //izmjena tipa TreeNode node = treeView1.SelectedNode; if (node.Tag is Tip) { Tip tip = (Tip)node.Tag; Tabelarni_prikaz_tipa.koZoveDodaj = "izmjeni"; FormTip ftip = new FormTip(tip, this); DialogResult r = ftip.ShowDialog(); refreshTree(); } }
private void buttonIzmjena_Click(object sender, EventArgs e) { koZoveDodaj = "izmjeni"; Tip tip = new Tip(textBoxId.Text, textBoxIme.Text, textBoxOpis.Text, pictureBoxTip.BackgroundImage); FormTip ftip = new FormTip(tip, main); DialogResult r = ftip.ShowDialog(); dataGridViewTip.Rows.Clear(); foreach (Tip t in tipovi) { dataGridViewTip.Rows.Add(new object[] { t.ID, t.Ime, t.Opis }); dataGridViewTip.Rows[dataGridViewTip.Rows.Count - 1].Tag = t; } ucitavanje = false; dataGridViewTip.CurrentCell = dataGridViewTip.Rows[0].Cells[0]; dataGridViewTip_SelectionChanged(dataGridViewTip, EventArgs.Empty); buttonDodavanje.Enabled = true; buttonIzmjena.Enabled = true; buttonBrisanje.Enabled = true; }
private void buttonDodavanje_Click(object sender, EventArgs e) { koZoveDodaj = "dodaj"; FormTip tip = new FormTip(main); DialogResult r = tip.ShowDialog(); dataGridViewTip.Rows.Clear(); foreach (Tip t in tipovi) { dataGridViewTip.Rows.Add(new object[] { t.ID, t.Ime, t.Opis }); dataGridViewTip.Rows[dataGridViewTip.Rows.Count - 1].Tag = t; } ucitavanje = false; dataGridViewTip.CurrentCell = dataGridViewTip.Rows[0].Cells[0]; dataGridViewTip_SelectionChanged(dataGridViewTip, EventArgs.Empty); buttonDodavanje.Enabled = true; buttonIzmjena.Enabled = true; buttonBrisanje.Enabled = true; main.refreshTree(); }