Re: [BLACKBOX] Program freezes when window loses focus

From: [at]} <Wojtek>
Date: Tue, 15 Mar 2011 16:20:40 -0400

----boundary-LibPST-iamunique-756912098_-_-
Content-type: text/plain

> Thanks for the reply. I can write to the log, as well as to my display
> window. Writing to this display window displays the contents of a string
> variable, whose contents are presumably replaced on each write, rather
> than appended, so the memory required presumably would not grow.

Not true. The Log displays an in-memory Text, which is growing on each
append. BB will be slowed down when this Text grows to large size. On the
other hand, writing to Log is easy.

A better way is to use a few interactors in your module, generate a Form,
and put calls to Dialog.Update in various places in your algorithm. You
will then see the numbers changing in the form, what gives you good
indication of progress. For example, display a loop counter and you will
see if the loop is still running.

> The log
> and everything else in the main BlackBox window, including the source code
> window and the display window, freeze and I cannot regain control, if I
> once do something to lose the focus from the display window once the
> program is running.Steve Troy

Indicative of an infinite loop where the program is stuck in an iteration
without an exit condition. Happened to me a few times.

Use the Form and you will quickly find out where the program gets stuck.

Wojtek


----
To unsubscribe, send a message with body "SIGNOFF BLACKBOX" to LISTSERV{([at]})nowhere.xy----boundary-LibPST-iamunique-756912098_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"
e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZmYwe1xmb250dGJsDQp7XGYwXGZz
d2lzcyBBcmlhbDt9DQp7XGYxXGZtb2Rlcm4gQ291cmllciBOZXc7fQ0Ke1xmMlxmbmlsXGZjaGFy
c2V0MiBTeW1ib2w7fQ0Ke1xmM1xmbW9kZXJuXGZjaGFyc2V0MCBDb3VyaWVyIE5ldzt9fQ0Ke1xj
b2xvcnRibFxyZWQwXGdyZWVuMFxibHVlMDtccmVkMFxncmVlbjBcYmx1ZTI1NTt9DQpcdWMxXHBh
cmRccGxhaW5cZGVmdGFiMzYwIFxmMFxmczIwID4gVGhhbmtzIGZvciB0aGUgcmVwbHkuICBJIGNh
biB3cml0ZSB0byB0aGUgbG9nLCBhcyB3ZWxsIGFzIH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