G
Guest
How can I update a WinForm without stealing focus?
I have a main form which has a Timer to perform updates (query data and
display it on the form). (Yes, it uses Invoke.) I also have menu items that
can display dialogs to set various things.
The problem is that when I have a dialog open and the timer updates the main
form, the main form steals the focus from the dialog.
As a work-around I have the app stop the updates while a dialog is open, but
I'd prefer to be able to have the updates occur without the focus being
stolen from the dialog.
I have a main form which has a Timer to perform updates (query data and
display it on the form). (Yes, it uses Invoke.) I also have menu items that
can display dialogs to set various things.
The problem is that when I have a dialog open and the timer updates the main
form, the main form steals the focus from the dialog.
As a work-around I have the app stop the updates while a dialog is open, but
I'd prefer to be able to have the updates occur without the focus being
stolen from the dialog.