private void SetStatusBar(string text) { if (StatusStrip1.InvokeRequired) { var del = new Action(() => SetStatusBar(text)); StatusStrip1.BeginInvoke(del); } else { StatusLabel.Text = text; StatusStrip1.Update(); } }
private void SetServerTime(string serverTime) { if (StatusStrip1.InvokeRequired) { var del = new Action(() => SetServerTime(serverTime)); StatusStrip1.BeginInvoke(del); } else { DateTimeLabel.Text = serverTime; StatusStrip1.Update(); } }
private void ConnectStatus(string text, Color foreColor, Color backColor, string toolTipText) { if (StatusStrip1.InvokeRequired) { var del = new Action(() => ConnectStatus(text, foreColor, backColor, toolTipText)); StatusStrip1.BeginInvoke(del); } else { ConnStatusLabel.Text = text; ConnStatusLabel.ToolTipText = toolTipText; ConnStatusLabel.ForeColor = foreColor; StatusStrip1.BackColor = backColor; StatusStrip1.Update(); } }
/// <summary> /// Set the text in the ToolStripStatusLabel. /// </summary> /// /// <param name="status"> the text to display </param> private void UpdateStatusLabel(string status) { ToolStripStatusLabel1.Text = status; StatusStrip1.Update(); }
/// <summary> /// Set the text in the ToolStripStatusLabel. /// </summary> /// /// <param name="status"> the text to display </param> private void UpdateStatusLabel(string status) { lblStatus.Text = status; StatusStrip1.Update(); }