private void ChangeMaxLabel(string s) { if (this.MaxEmail.InvokeRequired) { LabelDelagate d = new LabelDelagate(ChangeMaxLabel); this.Invoke(d, new Object[] { s }); } else { MaxEmail.Text = s; } }
private void UpdateLabelWithInvoke(Label label, string text) { if (label.InvokeRequired) { LabelDelagate d = UpdateLabelWithInvoke; Invoke(d, label, text); } else { label.Text = text; } }
private void ChangeCurrentFolderLabel(string folder) { if (FolderLabel.InvokeRequired) { LabelDelagate d = new LabelDelagate(ChangeCurrentFolderLabel); this.Invoke(d, new Object[] { folder }); } else { FolderLabel.Text = folder; } }