private void ShowOverlayText(string text) { if (false == OverlayTextBox.Visible) { OverlayTextBox.ForeColor = Color.FromKnownColor(KnownColor.ControlText); OverlayTextBox.Text = text; OverlayPanel.Visible = true; OverlayPanel.BringToFront(); } }
private void ShowOverlayError(Exception exception) { if (false == OverlayTextBox.Visible) { OverlayTextBox.ForeColor = Color.Red; OverlayTextBox.Text = "An unexpected error occured." + Environment.NewLine + Environment.NewLine + exception.ToString(); OverlayPanel.Visible = true; OverlayPanel.BringToFront(); } }