Beispiel #1
0
        private void NotifyFeatureCommandsCollectionFinish(object sender, NotifyFeatureCommandsCollectionFinishEventArgs e)
        {
            if (e.Result.Success)
            {
                YesNo autoClose = Launcher.AutoClose;
                if (autoClose == YesNo.Yes)
                {
                    CloseForm();
                }

                if (UserInformationFirstLineLabel.InvokeRequired)
                {
                    var d = new SafeUpdateFinishButtonDelegate(UpdateFinishButton);
                    FeatureLabel.Invoke(d);
                }
                else
                {
                    UserInformationFirstLineLabel.Visible  = false;
                    UserInformationSecondLineLabel.Visible = false;
                    FinishButton.Visible = true;
                    FinishButton.Refresh();
                }
            }
            else
            {
                MessageBox.Show(e.Result.Errors.AsMessages().ToStringBuilder().ToString(), @"Error", MessageBoxButtons.OK);

                CloseForm();
            }
        }
Beispiel #2
0
        private void NotifyFeatureCommandsCollectionFinish(object sender, NotifyFeatureCommandsCollectionFinishEventArgs e)
        {
            if (e.Result.Success)
            {
                YesNo autoClose = Launcher.AutoClose;
                if (autoClose == YesNo.Yes)
                {
                    CloseForm();
                }

                UserInformationFirstLineLabel.Visible  = false;
                UserInformationSecondLineLabel.Visible = false;
                FinishButton.Visible = true;
            }
            else
            {
                MessageBox.Show(e.Result.Errors.AsMessages().ToStringBuilder().ToString(), @"Error", MessageBoxButtons.OK);

                CloseForm();
            }
        }
Beispiel #3
0
        private static void NotifyFeatureCommandsCollectionFinish(object sender, NotifyFeatureCommandsCollectionFinishEventArgs e)
        {
            if (e.Result.Success)
            {
                Console.WriteLine($@"  > IIs configured correctly");
                Console.WriteLine($@"    > Enjoy!!! ;)");
            }
            else
            {
                var messages = new StringBuilder();
                foreach (var error in e.Result.Errors)
                {
                    messages.AppendLine(error.Message);
                }

                Console.WriteLine($@"   > Error(s) while configure IIS");
                Console.WriteLine(string.Empty);
                Console.WriteLine($@"{messages}");

                Console.WriteLine(string.Empty);
                Console.WriteLine(@"> End Logging < ");
            }
        }
Beispiel #4
0
 /// <summary>
 /// Raises the <see cref="NotifyFeatureCommandsCollectionFinish"/> event.
 /// </summary>
 /// <param name="e">A <see cref="NotifyFeatureCommandsCollectionFinishEventArgs"/> that contains the event data.</param>
 private void OnNotifyFeatureCommandsCollectionFinish(NotifyFeatureCommandsCollectionFinishEventArgs e) => NotifyFeatureCommandsCollectionFinish?.Invoke(this, e);