private void SetControlText(Control control, string text) { if (this.InvokeRequired) { ControlTextMethod ctm = new ControlTextMethod(SetControlText); this.Invoke(ctm, new object[] { control, text }); } else { control.Text = text; } }
private void SetControlText(Control control, string text) { if (control.InvokeRequired) { ControlTextMethod controlTextMethod = new ControlTextMethod(SetControlText); control.Invoke(controlTextMethod, new object[] { control, text }); } else { control.Text = text; } Application.DoEvents(); }
private void SetControlText(Control control, string text) { if (control.InvokeRequired) { ControlTextMethod controlTextMethod = new ControlTextMethod(SetControlText); control.Invoke(controlTextMethod, new object[] { control, text }); } else { control.Text = text; } Application.DoEvents(); }