private void ConfigureUI()
        {
            pnlNewVersion.Visible = false;

            try
            {
                LoadSkin();

                // Check to see if we've already choosen a version of CB to run
                if (ManagementInterfaceClient.ManagementInterface.ProductID == null || ManagementInterfaceClient.ManagementInterface.ProductID.Length == 0)
                {
                    ChooseEdition(true);
                }

                /*if (Properties.Settings.Default.UpdateNotification && Utils.NotificationUtils.IsNewVersionAvailable(ManagementInterfaceClient.ManagementInterface.ProductID, Application.ProductVersion))
                {
                    pnlNewVersion.Visible = true;
                }*/

                LoadApplicationPermissions();

                this.Text = ManagementInterfaceClient.ManagementInterface.ProductDescription;
                mnuExpertMode.Checked = ManagementInterfaceClient.ManagementInterface.ExpertModeEnabled;
                ChangeUserMode(mnuExpertMode.Checked);

                mnuPurchase.Visible = true;
                if (Properties.Settings.Default.ManagementInterfaceType != WOSI.CallButler.ManagementInterface.CallButlerManagementInterfaceType.Hosted)
                {
                    // Check our license for this server
                    if (!ManagementInterfaceClient.ManagementInterface.IsFreeVersion)
                    {
                        DateTime expDate;

                        if (ManagementInterfaceClient.ManagementInterface.IsLicensed)
                        {
                            expDate = ManagementInterfaceClient.ManagementInterface.LicenseExpiration;
                        }
                        else
                        {
                            expDate = ManagementInterfaceClient.ManagementInterface.TrialExpiration;
                        }

                        global::Controls.LoadingDialog.HideDialog();

                        Forms.NagForm nagForm = new CallButler.Manager.Forms.NagForm();

                        if (expDate > DateTime.MinValue && expDate >= DateTime.Now)
                        {
                            int daysLeft = (int)((TimeSpan)(expDate - DateTime.Now)).TotalDays;

                            nagForm.StatusText = String.Format(CallButler.Manager.Utils.PrivateLabelUtils.ReplaceProductName(Properties.LocalizedStrings.MainForm_Expires), daysLeft);
                            nagForm.ShowDialog(this);

                        }
                        else if (expDate > DateTime.MinValue && expDate < DateTime.Now)
                        {
                            nagForm.StatusText = CallButler.Manager.Utils.PrivateLabelUtils.ReplaceProductName(Properties.LocalizedStrings.MainForm_Expired);
                            nagForm.StatusTextColor = Color.Firebrick;
                            pnlExpired.Visible = true;
                            nagForm.ShowDialog(this);
                        }
                        else
                        {
                            mnuPurchase.Visible = false;
                        }

                        if (nagForm.EnterLicense)
                            LicenseRegistration();
                    }
                }

                bool firstTime = !ManagementInterfaceClient.ManagementInterface.IsDownloadRegistered;

                if (firstTime || ManagementInterfaceClient.ManagementInterface.GetFirstTimeRun(ManagementInterfaceClient.AuthInfo))
                {
                    global::Controls.LoadingDialog.HideDialog();

                    ShowQuickStartWizard(firstTime, true);
                }
                else
                {
                    LoadViewControl(new SummaryView());
                }

                if (!this.Visible)
                    this.Show();

                // Show our info form
                string splashInfo = ManagementInterfaceClient.ManagementInterface.SplashInfo;

                if (splashInfo != null && splashInfo.Length > 0)
                {
                    Forms.StartInfoForm sif = new CallButler.Manager.Forms.StartInfoForm(splashInfo);

                    global::Controls.LoadingDialog.HideDialog();

                    sif.ShowDialog(this);
                }
            }
            catch (Exception e)
            {
                RemotingExceptionManager.ProcessException(e);
                return;
            }
        }
        private void ConfigureUI()
        {
            pnlNewVersion.Visible = false;

            try
            {
                LoadSkin();

                // Check to see if we've already choosen a version of CB to run
                if (ManagementInterfaceClient.ManagementInterface.ProductID == null || ManagementInterfaceClient.ManagementInterface.ProductID.Length == 0)
                {
                    ChooseEdition(true);
                }

                /*if (Properties.Settings.Default.UpdateNotification && Utils.NotificationUtils.IsNewVersionAvailable(ManagementInterfaceClient.ManagementInterface.ProductID, Application.ProductVersion))
                 * {
                 *  pnlNewVersion.Visible = true;
                 * }*/

                LoadApplicationPermissions();

                this.Text             = ManagementInterfaceClient.ManagementInterface.ProductDescription;
                mnuExpertMode.Checked = ManagementInterfaceClient.ManagementInterface.ExpertModeEnabled;
                ChangeUserMode(mnuExpertMode.Checked);

                mnuPurchase.Visible = true;
                if (Properties.Settings.Default.ManagementInterfaceType != WOSI.CallButler.ManagementInterface.CallButlerManagementInterfaceType.Hosted)
                {
                    // Check our license for this server
                    if (!ManagementInterfaceClient.ManagementInterface.IsFreeVersion)
                    {
                        DateTime expDate;

                        if (ManagementInterfaceClient.ManagementInterface.IsLicensed)
                        {
                            expDate = ManagementInterfaceClient.ManagementInterface.LicenseExpiration;
                        }
                        else
                        {
                            expDate = ManagementInterfaceClient.ManagementInterface.TrialExpiration;
                        }

                        global::Controls.LoadingDialog.HideDialog();

                        Forms.NagForm nagForm = new CallButler.Manager.Forms.NagForm();

                        if (expDate > DateTime.MinValue && expDate >= DateTime.Now)
                        {
                            int daysLeft = (int)((TimeSpan)(expDate - DateTime.Now)).TotalDays;

                            nagForm.StatusText = String.Format(CallButler.Manager.Utils.PrivateLabelUtils.ReplaceProductName(Properties.LocalizedStrings.MainForm_Expires), daysLeft);
                            nagForm.ShowDialog(this);
                        }
                        else if (expDate > DateTime.MinValue && expDate < DateTime.Now)
                        {
                            nagForm.StatusText      = CallButler.Manager.Utils.PrivateLabelUtils.ReplaceProductName(Properties.LocalizedStrings.MainForm_Expired);
                            nagForm.StatusTextColor = Color.Firebrick;
                            pnlExpired.Visible      = true;
                            nagForm.ShowDialog(this);
                        }
                        else
                        {
                            mnuPurchase.Visible = false;
                        }

                        if (nagForm.EnterLicense)
                        {
                            LicenseRegistration();
                        }
                    }
                }

                bool firstTime = !ManagementInterfaceClient.ManagementInterface.IsDownloadRegistered;

                if (firstTime || ManagementInterfaceClient.ManagementInterface.GetFirstTimeRun(ManagementInterfaceClient.AuthInfo))
                {
                    global::Controls.LoadingDialog.HideDialog();

                    ShowQuickStartWizard(firstTime, true);
                }
                else
                {
                    LoadViewControl(new SummaryView());
                }

                if (!this.Visible)
                {
                    this.Show();
                }

                // Show our info form
                string splashInfo = ManagementInterfaceClient.ManagementInterface.SplashInfo;

                if (splashInfo != null && splashInfo.Length > 0)
                {
                    Forms.StartInfoForm sif = new CallButler.Manager.Forms.StartInfoForm(splashInfo);

                    global::Controls.LoadingDialog.HideDialog();

                    sif.ShowDialog(this);
                }
            }
            catch (Exception e)
            {
                RemotingExceptionManager.ProcessException(e);
                return;
            }
        }