void miSelectConstructor_Click(object sender, EventArgs e) { MethodDiagramViewer mv = this.Parent as MethodDiagramViewer; if (mv != null) { AB_Constructor av = this.ActionObject as AB_Constructor; IConstructor cp = av.ActionData.ActionMethod as IConstructor; LocalVariable lv = cp.Owner as LocalVariable; dlgConstructorParameters dlg = new dlgConstructorParameters(); dlg.SetMethod(mv.DesignerHolder.Method); dlg.LoadData(lv); dlg.LocateConstructor(cp); if (dlg.ShowDialog(this.FindForm()) == DialogResult.OK) { cp.CopyFrom(dlg.Ret); mv.Changed = true; } } }