public MemberForm(ref Member m) { this.m = m; InitializeComponent(); if (m.IsEmpty) { state = "NEW"; } if (state.Equals("NEW")) { this.Text = "Ny Medlem"; action_button.Text = "Skapa"; } }
private void new_toolStripButton_Click(object sender, EventArgs e) { Member m = new Member(); var mf = new MemberForm(ref m); mf.ShowDialog(); }
private void nyMedlemToolStripMenuItem_Click(object sender, EventArgs e) { Member m = new Member(); var mf = new MemberForm(ref m); mf.ShowDialog(); MessageBox.Show(m.FirstName); }