At 1:07 AM -0600 11/4/06, Rubber Chicken Software Co. wrote:
However, the docs do say that DoEvents shouldn't be used in a GUI
app, saying it will lead to instability. Will it in this case?
There's only three things happening. A StaticText gets updated, a
ProgressBar is updated, and if a button gets pressed in the RB
interface, the callback returns false to the dylib, causing a Cancel.
In my experience, and from what I've read of this controversy,
App.DoEvents primarily causes problems when called from an
asychronous event (eg socket or serial) or from an RB thread. Search
the archives, I've posted summaries of RS's comments about this
before.
FWIW I have used DoEvents from a loop in the main thread to update a
simple UI similar to yours (Canvas, ProgressBar and Cancel button).
It worked OK for years and I even got one of the RB engineers who
opposes DoEvents to agree that this was probably a safe use. At the
time there wasn't much of an alternaive since threads with QuickTime
activity would crash.
Subsequently threads were fixed and I moved this code back to a
thread and stopped using DoEvents just to be safe.
Hope this helps,
Joe Huber
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>