Esempio n. 1
0
        public AddNewWordWindow(CreateOrEditTestWindow owner)
        {
            InitializeComponent();

            isCancel = false;
            result = new WordObject();
            _owner = owner;

            this.MaximumSize = new Size(Screen.PrimaryScreen.Bounds.Width, this.Height);
        }
Esempio n. 2
0
 public static WordObject ShowWindowDialog(string w, string tr, string pof, string title, CreateOrEditTestWindow owner)
 {
     AddNewWordWindow wnd = new AddNewWordWindow(owner);
     wnd.Text = title;
     wnd.textBox1.Text = w;
     wnd.textBox2.Text = tr;
     wnd.comboBox1.SelectedItem = pof;
     wnd.ShowDialog();
     if (!isCancel) return result;
     return null;
 }
 private void button1_Click(object sender, EventArgs e)
 {
     this.Close();
     if (radioButton1.Checked)
     {
         CreateOrEditTestWindow w = new CreateOrEditTestWindow();
         w.ShowDialog();
     }
     else
     {
         CreateOrEditVarTestWindow w = new CreateOrEditVarTestWindow();
         w.ShowDialog();
     }
 }
Esempio n. 4
0
 private void редактироватьToolStripMenuItem_Click(object sender, EventArgs e)
 {
     CreateOrEditTestWindow w = new CreateOrEditTestWindow();
     foreach (DataGridViewRow i in this.wordsTable.Rows)
         w.dataGridView1.Rows.Add(i.Cells[0].Value, i.Cells[1].Value, i.Cells[2].Value);
     w.ShowDialog();
 }