public static SimulationCreatorForm OpenDialog(MainForm parent) { SimulationCreatorForm dialogForm = new SimulationCreatorForm(); dialogForm.parentForm = parent; dialogForm.BeginDialog(); dialogForm.Show(); return(dialogForm); }
private void Button_StartSimulation_Click(object sender, EventArgs e) { SimulationCreatorForm form = SimulationCreatorForm.OpenDialog(this); }