SplashScreen.ShowNotificationMessage C# (CSharp) Method

ShowNotificationMessage() public method

public ShowNotificationMessage ( string message, string progressText, bool stopProgress, string commadTitle, MethodInvoker, command ) : void
message string
progressText string
stopProgress bool
commadTitle string
command MethodInvoker,
return void
    public void ShowNotificationMessage(string message, string progressText, bool stopProgress, string commadTitle, MethodInvoker command)
    {
        this.Invoke((MethodInvoker)delegate
        {
            Debug.Assert(this.Visible);

            this.Height = 250;
            OK.Visible =
            notification.Visible = true;
            notification.Text = message;

            label1.Text = progressText;
            progressBar1.Enabled = !stopProgress;
            progressBar1.Style = System.Windows.Forms.ProgressBarStyle.Blocks;
            progressBar1.Value = progressBar1.Minimum;

            linkLabel1.Visible = true;
            linkLabel1.Text = commadTitle;
            this.notificationCommand = command;
        });
    }

Usage Example

Example #1
0
 public static void ShowNotification(string message, string progressLabel, bool stopProgressbar, string commadTitle, MethodInvoker command)
 {
     try
     {
         //instance.Invoke((MethodInvoker)delegate { Application.ExitThread(); });
         instance.ShowNotificationMessage(message, progressLabel, stopProgressbar, commadTitle, command);
     }
     catch { }
 }