private void FormClosedCallback(Object sender, FormClosedEventArgs e) // called when form closes.. by user or by us. Remove from list { UserControlForm tcf = (UserControlForm)sender; tabforms.Remove(tcf); discoveryform.ActionRun(Actions.ActionEventEDList.onPopDown, new BaseUtils.Variables(new string[] { "PopOutName", tcf.DBRefName.Substring(9), "PopOutTitle", tcf.WinTitle })); }
public UserControlForm NewForm() // a new form is needed { UserControlForm tcf = new UserControlForm(); tabforms.Add(tcf); tcf.FormClosed += FormClosedCallback; return(tcf); }