示例#1
0
        private void ShowFormAccount()
        {
            #region Show Form Account
            foreach (Form form in Application.OpenForms)
            {
                if (form.GetType() == typeof(FormAccount)) //<<FormName
                {
                    form.WindowState = FormWindowState.Normal;
                    form.BringToFront();
                    form.Focus();
                    return;
                }
            }

            FormAccount formAccount = new FormAccount {
                MdiParent = this
            };
            formAccount.Show();
            formAccount.Activate();
            formAccount.Focus();
            #endregion Show Form Account
        }
示例#2
0
 public FormAccount()
 {
     InitializeComponent();
     Forms = this;
 }