theForm.InvokeRequired or theElement.InvokeRequired
-
Hello I call FORM elements from another thread. I use Invoke/BeginInvoke for that. I access a TextBox and a ProgressBar. Can I use
theForm.InvokeRequired ...
to access both elements or do I have to check if for each element:textBox.InvokeRequired ... progressBar.InvokeRequired
Thanks Martin -
Hello I call FORM elements from another thread. I use Invoke/BeginInvoke for that. I access a TextBox and a ProgressBar. Can I use
theForm.InvokeRequired ...
to access both elements or do I have to check if for each element:textBox.InvokeRequired ... progressBar.InvokeRequired
Thanks MartinAs one can assume that all controls on one Form are created within the same thread you can safely just check the Form.
-
Hello I call FORM elements from another thread. I use Invoke/BeginInvoke for that. I access a TextBox and a ProgressBar. Can I use
theForm.InvokeRequired ...
to access both elements or do I have to check if for each element:textBox.InvokeRequired ... progressBar.InvokeRequired
Thanks MartinOnly once :) All the controls would have been created on one thread :)**
xacc.ide-0.1.3.14 - Now with syntax support for PowerShell
xacc.ide-0.1.3.13 source code**
-
As one can assume that all controls on one Form are created within the same thread you can safely just check the Form.
Arggg, twice in a row I was only minutes too late ;P**
xacc.ide-0.1.3.14 - Now with syntax support for PowerShell
xacc.ide-0.1.3.13 source code**