Пример #1
0
 public static void subCloseSystemSetup()
 {
     try
     {
         objSystemSetup.Close();
         objSystemSetup.Dispose();
         objSystemSetup = null;
     }
     catch (Exception ex)
     {
         clsErr.subLogErr("subCloseSystemSetup", ex);
     }
 }
Пример #2
0
        public static void subShowSystemSetup(Form _mdiParent)
        {
            try
            {
                if (objSystemSetup == null || objSystemSetup.IsDisposed) objSystemSetup = new frmSystemSetup();

                objSystemSetup.MdiParent = _mdiParent;

                objSystemSetup.Show();
            }
            catch (Exception ex)
            {
                clsErr.subLogErr("subShowSystemSetup", ex);
            }
        }
Пример #3
0
        public static void Main()
        {
            //Xceed.DockingWindows.Licenser.LicenseKey = "DWN10-DF7YB-F7UBP-1ABA";
            //Xceed.Grid.Licenser.LicenseKey = "GRD25-G17KB-F7BMP-U4JA";
            //Xceed.Editors.Licenser.LicenseKey = "EDN10-PF7YB-E7BUD-1AAA";
            Xceed.SmartUI.Licenser.LicenseKey = "SUN33-LF7DB-1WBBP-34CA";

            //Telerik.WinControls.Themes.BreezeTheme theme = new Telerik.WinControls.Themes.BreezeTheme();
            //theme.DeserializeTheme();
            //Telerik.WinControls.ThemeResolutionService.ApplicationThemeName = "Breeze";

            if (!fcnSetWSVars())
            {
                MessageBox.Show("This is the first time you have run this program, please fill in the following setup screens.");

                frmSystemSetup frmSetup = new frmSystemSetup();

                Application.Run(frmSetup);
            }

            bool blnMainGood;

            if (blnUseSQLServer)
                blnMainGood = fcnBuildSQLConnect(strRegKey, ref clsAppSettings.GetAppSettings().strCTConn);
            else
                blnMainGood = fcnRelink("ctmain_b.mdb", strRegKey, "MainPath", ref clsAppSettings.GetAppSettings().strCTConn);

            if (!blnMainGood)
            {
                MessageBox.Show("Cannot open system without locating data files!");

                frmSystemSetup frmSetup = new frmSystemSetup();

                Application.Run(frmSetup);
                MessageBox.Show("Please restart the program");
                return;
            }

            clsAppSettings.GetAppSettings().subInitSettings();

            subStructureUpdateMDB();

            clsNav.objLogin = new frmLogin();

            Application.Run(clsNav.objLogin);
        }