Selecting track directly by name not working
Title
Selecting track directly by name not working
What do you expect to happen when you run the script/macro?
Working toward building a macro that will help me bounce various types of stems that are built into my template / track presets. I select my mix and mstr tracks to record enable and disable again so that record-monitoring is turned off. Those selections work fine, but I can't get it to select my STEMS_DRUMS track in order to arm it and record.
Is there a way to directly access the record arm?
What's odd is that when I first started working on this, that part of the macro worked. I'm not sure where I messed it up.
Are you seeing an error?
Sometimes nothing. Sometimes it works. Mostly it says "No track selected". I am not sure how to isolate the fluctuation.
What happens when you run this script?
Everything until the last two commands work
How were you running this script?
I clicked the "Run Script" or "Run Macro" button in SoundFlow
How important is this issue to you?
5
Details
{ "inputExpected": "Working toward building a macro that will help me bounce various types of stems that are built into my template / track presets. I select my mix and mstr tracks to record enable and disable again so that record-monitoring is turned off. Those selections work fine, but I can't get it to select my STEMS_DRUMS track in order to arm it and record.\n\nIs there a way to directly access the record arm?\n\nWhat's odd is that when I first started working on this, that part of the macro worked. I'm not sure where I messed it up.", "inputIsError": true, "inputError": "Sometimes nothing. Sometimes it works. Mostly it says \"No track selected\". I am not sure how to isolate the fluctuation.", "inputWhatHappens": "Everything until the last two commands work", "inputHowRun": { "key": "-MpfwYA4I6GGlXgvp5j1", "title": "I clicked the \"Run Script\" or \"Run Macro\" button in SoundFlow" }, "inputImportance": 5, "inputTitle": "Selecting track directly by name not working" }
Source
//Macro converted to script
sf.ui.proTools.appEnsureIsRunning();
sf.ui.proTools.appActivateMainWindow();
(throw 'context missing').setRecordMode();
sf.ui.proTools.memoryLocationsGoto({
memoryLocationNumber: 1,
extendSelection: false,
});
//Calling command "Clear Record States" from package "Pro Tools" (installed from user/pkg/version "srAasovvDiQacRZ2mcId4RrOA8R2/ckp49i4j60000a2100yfwywgf/cm5fn5kmt00001d10sopm2o30")
sf.soundflow.runCommand({
commandId: 'user:ckp49i4j60000a2100yfwywgf:ck1wluk7h000b1n10vm9rwijk',
props: {}
});
//Calling command "New Track with Track Preset" from package "Pro Tools" (installed from user/pkg/version "srAasovvDiQacRZ2mcId4RrOA8R2/ckp49i4j60000a2100yfwywgf/cm5fn5kmt00001d10sopm2o30")
sf.soundflow.runCommand({
commandId: 'user:ckp49i4j60000a2100yfwywgf:ckftk383t00005t10fis94s21',
props: {
trackPresetPath: ["STR Automation","STEM PRINTS (MIX)"],
}
});
sf.ui.proTools.trackGetByName({ name: "BASS", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGetByName({ name: "GTRS", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGetByName({ name: "BASS", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGetByName({ name: "KEYS", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGetByName({ name: "MISC FX", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGetByName({ name: "ALL VOX", makeVisible: true }).track.trackSetMute({
targetValue: "Enable",
});
sf.ui.proTools.trackGotoByInputName({
inputName: "MSTR",
});
sf.ui.proTools.selectedTrack.buttons.whoseTitle.is("Track Record Enable").first.mouseClickElement();
sf.ui.proTools.selectedTrack.buttons.whoseTitle.is("Track Record Enable").first.mouseClickElement();
sf.ui.proTools.trackGotoByInputName({
inputName: "MIX",
});
sf.ui.proTools.selectedTrack.buttons.whoseTitle.is("Track Record Enable").first.mouseClickElement();
sf.ui.proTools.selectedTrack.buttons.whoseTitle.is("Track Record Enable").first.mouseClickElement();
sf.ui.proTools.trackGetByName({ name: "STEM_DRUMS", makeVisible: true }).track.trackSelect();
sf.ui.proTools.selectedTrack.buttons.whoseTitle.is("Track Record Enable").first.mouseClickElement();
Links
User UID: P7isFIRms6YQiecxxlGDhbvNXFL2
Feedback Key: sffeedback:P7isFIRms6YQiecxxlGDhbvNXFL2:-OHXAQ1sDolfYi_rpXZk
Feedback ZIP: FOu/tQ1SHhO+EbomtccefwRAbQ3jLlPJCJwoR54UoJ3o5z/VVN8rbSsjpvkCkg20TMJqUc1zmQlm1PoK7cJARUgrk4gxfjRX6Z2xrAlrW2f+hKvk56x2267JQjn/MKg+LnBwK33jC+7TKvEMPpDQa8vZX7fJJsm/qmg7tTIC/X+MHeXLctMn/fKOXE6fv8OFy+U3PX68k3xxXzWiK6CHqnhHfhjUrRLS2AJNfOmjyOT9s5L7CwRLMA/knoyWYI/JbO/WXM93R4oaYQoWyLuNuFlZ6HjMGuG8eeGp0CKv0l6H9CRXH/DbIY42xMjGhGRULjl/AoRVY2VKOkUBCGY1NGWJKY/EG6bWKW++DZv1TzU=