How do you assign scripting names with the Js object?
More specifically, I want to be able to assign unique names to dynamically instantiated objects and then send specific messages to specific objects. Any ideas on how to do this?
Here is what I do:
function setpatchername (aString)
{
if (aString != "#1") // so, no error when #1 received
this.patcher.box.varname = aString;
outlet (0,"bang");
}
Max Patch
Copy patch and select New From Clipboard in Max.
I use this code like this:
HtH,
p
you mean something like this:
this.patcher.newdefault(50, 5, "nslider", "@presentation", 1, "@presentation_position",
50, 5, "@mode", 1, "@varname", "myName");
Yes brilliant, thanks guys.
I'm getting "varname" is not a valid attribute argument for a jit.qt.movie object...