I am using sprintf to assemble some command strings, and I need to include a comma character
For example, my sprintf looks like this:
sprintf symout send z%i min
and I want the output to look like
send z1, min < - note the comma
It looks like I can’t include the standard ASCII escaping, eg 54 for comma.
How can I do this?
[ sprintf symout send z%i, min ]
[ sprintf symout send z%ld, min ]
You can use a backslash to escape a reserved character in objects like [sprintf] and [expr]. Try without the "symout" argument otherwise it will all be one message and won’t work if you try to send it to [forward].
[sprintf send z%i, min]
If I don’t include symout then forward kicks back "forward: first extra argument must be a symbol".
If I do include symout, then the forward doesn’t seem to take effect.
What seems to work is (t b i) to fire off the (sprintf send z%i) and then (min).
Is there a simpler way to do this? I just want to selectively send messages to a number of consecutively named (receive) objects.
[t min i] ?
Log in to reply
C74 IN YOUR INBOX
C74 RSS Feed | © Copyright Cycling '74 | Terms & Conditions
Let us tell you about notable Max projects, obscure facts, and creative media artists of all kinds.