Hello, I'm new to this and was trying to setup a macro/script that allows me Freeze and Unfreeze a track in Ableton.
I managed to setup the macro that freeze the track using the "click menu item" action, but as it changes the name I can't use the macro as a toggle button.
Is there a way to do this?
Also, when you select multiple tracks, the menu item automatically put the plural "s" on the word "track" and the macro doesn't work.
Hope I was clear, looking for your advices!
- Raphael Sepulveda @raphaelsepulveda2022-01-25 19:40:29.993Z
Hey @Matteo_Zedda, welcome to SoundFlow!
Give this a shot:
function freezeUnfreezeTrack() { const menuItem = sf.ui.abletonLive.getMenuItem('Edit').children.first.children.filter(c => { return c.title.value.match(/[Un]?Freeze Track[s]?/i); })[0]; menuItem && menuItem.elementClick(); } freezeUnfreezeTrack();
- MMatteo Zedda @Matteo_Zedda
Also this works!
Is it possible to setup the "s" plural thing also for the "Flatten Track(s)" command?Raphael Sepulveda @raphaelsepulveda2022-01-25 20:53:34.391Z
This should do!
function flattenTrack() { const menuItem = sf.ui.abletonLive.getMenuItem('Edit').children.first.children.filter(c => { return c.title.value.match(/Flatten Track[s]?/i); })[0]; menuItem && menuItem.elementClick(); } flattenTrack();
- MMatteo Zedda @Matteo_Zedda
Thanks a lot!
- JJohn Frame @John_Frame
Hey Newbie here but where does this code go? Is this an AppleScript that needs to be called? Thanks!
Raphael Sepulveda @raphaelsepulveda2022-05-13 06:05:31.874Z
Hey @John_Frame, welcome to SoundFlow!
Check out the following video to learn how to utilize scripts from the forum: https://www.youtube.com/watch?v=3FQrVMNck-8
- JJohn Frame @John_Frame
Thanks! That helped. I had a quick follow-up question that I couldn't find in the Forum...what programming language is used in Soundflow, is it custom?
Raphael Sepulveda @raphaelsepulveda2022-05-13 19:16:09.017Z
JavaScript!