Beispiel #1
0
        protected override void OnLaunch()
        {
            try
            {
                base.OnLaunch();
                FrameworkManager.CreateCulture();

                // TEMP
                // FrameworkManager.GenerateLicence();
                // FrameworkManager.CreateLicenceTrial("admin", "admin");
                // FrameworkManager.CreateLicenceStandard("pos", "*****@*****.**");

                // Check AppInit

                var setting = new ElvaSettings().getInstance();

                FrameworkManager.CheckValidation();

                if (setting.AppInitialized == false)
                {
                    MessageBox.Show("Configuration de premiére utilisation");

                    // Setup modules
                    FrameworkManager.UpdateModules();

                    // setup series
                    FrameworkManager.CreateSeries();

                    setting.AppInitialized = true;
                    setting.Save();

                    MessageBox.Show("Configuration terminée");
                }
            }
            catch (Exception s)
            {
                MessageBox.Show(s.Message);
            }
        }