Re: Event handling stops for no reason? [message #69980 is a reply to message #69978] |
Thu, 04 March 2010 08:09   |
MichaelT
Messages: 52 Registered: May 2006
|
Member |
|
|
> Sometimes things happen faster than you can think, or not.
> I have, on occasion, put a Wait, 0.1 into my code to slow
> things down a bit. This seems to be a timing issue now.
Yep, I have frequently used this for loops which otherwise took ages
to complete. However, in this case, it did not help...
I was able to reproduce the behavior several times now. The program is
really in a state of not doing anything. It is not stuck at a line of
code.
When I interrupt processing using this little red square (Cancel? Have
a German IDL version), the GUIs are closed and the program terminated.
IDL does not jump to a line in my code like it usually would. It
really seems that the event is hanging around somewhere? And the
program is supposed to automatically process a large number of files
over night...
I experimented with timer events to wake up IDL. That seemed to work.
More mysteries...
As this was so totally annoying, I now modified the code and send the
"event" directly (main module's object ID stored in group leader's
uValue):
Widget_Control, self.Group_Leader, Get_uValue = AviStack2
AviStack2->Event, {Processing, 0L, 0L, 0L, ok, self.preset}
I had to modify the code of my main module only slightly and
substituted the send_event in about 20 objects... I don't really like
it this way. But, it is working!
> P.S. Have you ever thought maybe this program design
> was *too* clever? ;-)
This is so spot on :-)))
Thanks for your help!
Michael
|
|
|