Forums > Javascript

Renaming a Live dial

Mar 14 2011 | 1:53 am


I’m am trying to rename a live.dial in a javascript using the following:

var c1 = this.patcher.getnamed("controller1");"new name";

This does’t seem to work, neither does "shortName". I’m shooting in the dark as to what property/method I should use. Or maybe I should be using the Live API. I don’t seem to be having much success at firing a "set name xxx" message at a live.object either.

Mar 14 2011 | 4:06 am

As with most parameter attributes, this cannot be changed programatically. Live needs to know things such as the name, range, unit style, modulation mode, etc, when the object is instantiated in Live. The only supported way to change these things is via the object inspector (or the ‘Parameters’ window) in the Max editor.


Mar 16 2011 | 2:14 pm

Thanks for that info.

Did I not want to hear that :)

Mar 28 2012 | 4:30 pm

Any chance of providing ways of doing this at instantiation time? (I’m guessing that would be safe?)

I’m working on something that automatically constructs guis, and it would be really nice if I could use the live. objects for this, since they have so many useful features built-in. (like the rawfloat (or instant midi mapping message as I tend to think of it))

Dec 17 2014 | 10:25 am

Send a message to any live.object saying _parameter_shortname $1 $2 to change the name after initialization

Mar 15 2015 | 11:18 pm

10guitars: excellent. Is this a private api? If not, are these types of calls and valid params listed anywhere?

For example, I am writing a simple M4L device to map one parameter to another (f.ex. to assign a rack macro to a random control in the set) and would love to be able to set units, range, type, etc.


Mar 16 2015 | 2:02 am

The short name is generally safe to change after instantiation (it’s used for display in Live’s GUI, but not for identification). Changing the long name will set you up for a world of hurt, as will most of the other semi-secret parameter attributes. Which are "secret" for a reason, namely to prevent you from causing crashes or other undefined behavior.

When the device is instantiated, Live collects this information exactly once. Changing it after the fact will cause Live and Max to get out of sync.

There is currently no way to dynamically create valid, functioning parameters in realtime in Max for Live. That limitation is unlikely to change anytime soon. The "Macro Parameter" approach (e.g. a predefined bank of assignable pots) is the best approach here.

Jan 03 2016 | 4:24 pm

You can change live.dial’s long name if you check "link to scripting name" beforehand and then send a "varname foo" message on initialization. And on the "_parameter_shortname $1 $2", it seems like all the (hidden) parameter attributes can be accessed in this way. I understand why use of this functionality is discouraged, but why is it included but undocumented?

Viewing 8 posts - 1 through 8 (of 8 total)

Forums > Javascript