Razzo78
12/17/2018 - 2:54 PM

C# - Update UI control thread-safe

C# - Update UI control thread-safe

public void ControlInvokeRequired(Control control, Action action)
{
    if (control.InvokeRequired) control.Invoke(new MethodInvoker(delegate { action(); }));
}