Beispiel #1
0
        protected void LoadMainForm()
        {
            if (this.IsDeployed && this.GetType().Name == "MainForm")
            {
                string mainWindowName = "ADA Main";

                if (this.Text != mainWindowName)
                {
                    string application = Assembly.GetExecutingAssembly().GetModules()[0].FullyQualifiedName;
                    string mainApp     = Path.GetDirectoryName(application) + "\\AdaMainPpc.exe";

                    FormEngine.BringWindowToTop(mainWindowName, mainApp);
                }
            }
        }
Beispiel #2
0
        private void AdaBaseForm_Closed(object sender, EventArgs e)
        {
            if (this.IsDeployed && this.GetType().Name == "MainForm")
            {
                string mainWindowName = "ADA Main";

                if (this.Text != mainWindowName)
                {
                    string application = Assembly.GetExecutingAssembly().GetModules()[0].FullyQualifiedName;
                    string mainApp     = Path.GetDirectoryName(application) + "\\AdaMainPpc.exe";

                    FormEngine.BringWindowToTop(mainWindowName, mainApp);
                }
            }
        }