S
schaf
Hi All!
I have a challenging task.
My app is split into two parts, a Base and a Main part.
Now I would like to create a controller class, which handles all
notifications (UI dialog similar to message boxes) from both parts.
The application contains multiple threads and therefore I need to
synchronize the creation of the notification to the main thread,
especially if I would like to handover the main UI-Handle to the
notification.show method.
But the first base function could send a notification before my main
UI is created. So I can not synchronize the notification to the UI
thread, neither by using Invoke nor by using the
SynchronizationContext. Is there a solution, where I can create a
SynchronizationContext for the main UI thread, before the UI creation
is finished?
Or is it not possible to synchronize such a behavior?
Thanks
Marcel
I have a challenging task.
My app is split into two parts, a Base and a Main part.
Now I would like to create a controller class, which handles all
notifications (UI dialog similar to message boxes) from both parts.
The application contains multiple threads and therefore I need to
synchronize the creation of the notification to the main thread,
especially if I would like to handover the main UI-Handle to the
notification.show method.
But the first base function could send a notification before my main
UI is created. So I can not synchronize the notification to the UI
thread, neither by using Invoke nor by using the
SynchronizationContext. Is there a solution, where I can create a
SynchronizationContext for the main UI thread, before the UI creation
is finished?
Or is it not possible to synchronize such a behavior?
Thanks
Marcel