11-01-2009 09:35 PM
Is there a no-wait version of MessagePopup? I need to inform user of a condition without causing the program to wait for a response.
The program is acquiring data continuously and can't stop to wait for user to click OK.
11-01-2009 11:52 PM
The main question here is how your program is designed. If your acquisition is done via a UI timer, an asyncronous timer or a separate thread it will not be interrupted by a MessagePopup, unless it is issued in the exact function that is performing the acquisition (e.g. a MessagePopup called inside the async timer callback).
If this is your case, I suggest you use PostDeferredCall to call a callback outside the acquisition function (deferred callbacks are executed in the main thread, where normally runs the user interface). The callbackData parameter can be used to transmit informations to the deferred function.
On the other hand, if your acquisition is done within a control callback that runs a long loop... I suggest you to move to one of the structures I mentioned above!
11-02-2009 03:23 AM - edited 11-02-2009 03:25 AM
If the state of the acquisiton does not depend on the user's input (since you want to continue acquisition in the bacground), then you may not have to use a popup to inform the user.
Just update a text control on your UI. Isn't that sutiable enough for your needs?
If you have to use a popup, then multi-threading is the only option.