How do I automatically output a Bang when content of a message changes?

Max Baxter's icon

Hi friends,

I have a message box that is constantly changing. How can I output a bang automatically when the content of the message changes, without manually sending a bang and using zl.change?

Thanks

Charly Beck's icon

no way i guess. but you can put a trigger "t b l" in front of the message box and connect first outlet of trigger to first inlet of message box and second outlet of trigger to second inlet. you may add this to a patcher.

but btw.... from logical point of view there is no reason to use a message box if the output gets flushed immediatelly... if you want this for debugging purpose you should better use watchpoints because the message boxes do not get refreshed when using breakpoints and step -by-step execution. (this is a drawback of max)

you enable watchpoints by right clicking the cable and select "set watchpoint". there are 3 kinds of watchpoints. one which outputs to the logger window, one which stops the runtime and allows step by step execution and one which shows a small message beside the cable (that comes close to the approach of adding various message boxes)

Peter Ostry's icon

If you don't need/want the message box:

For instant update
[t b l]
[zl reg]
[zl change]
or for regular update
[metro]
[zl reg]
[zl change]

If you want to read the text you may additionally use [prepend set] to a comment box which has more formatting options than a message box.