Assign tracks in eucon no longer assigning all selected tracks
Title
Assign tracks in eucon no longer assigning all selected tracks
What do you expect to happen when you run the script/macro?
the script is only assigning the last selected track, not ALL selected tracks to faders.
is it possible to add a close window option to this script?
thanks!!
Are you seeing an error?
What happens when you run this script?
the script is only assigning the last selected track, not ALL selected tracks to faders.
is it possible to add a close window option to this script?
thanks!!
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": "the script is only assigning the last selected track, not ALL selected tracks to faders. \n\nis it possible to add a close window option to this script?\n\nthanks!!", "inputIsError": false, "inputWhatHappens": "the script is only assigning the last selected track, not ALL selected tracks to faders. \n\nis it possible to add a close window option to this script?\n\nthanks!!", "inputHowRun": { "key": "-MpfwYA4I6GGlXgvp5j1", "title": "I clicked the \"Run Script\" or \"Run Macro\" button in SoundFlow" }, "inputImportance": 5, "inputTitle": "Assign tracks in eucon no longer assigning all selected tracks" }
Source
var eucon = sf.ui.app('com.Euphonix.EuControl');
eucon.appActivate();
eucon.getMenuItem("Window", "EuControl Settings").elementClick();
var win = eucon.windows.whoseTitle.is('EuControl Settings').first;
win.elementWaitFor();
//Switch to Assign tab
win.tabGroups.first.radioButtons.whoseTitle.is('Assign').first.elementClick();
win.tabGroups.first.checkBoxes.whoseTitle.is('Display Application\'s Track Numbers').first.elementWaitFor();
//Clear existing assignments
win.tabGroups.first.buttons.whoseTitle.is('Clear All Assignments').first.elementClick();
//Init
var table = win.tabGroups.first.scrollAreas.first.tables.first;
var rows = table.childrenByRole("AXRow").allItems;
var selectedTrackNames = sf.ui.proTools.selectedTrackNames;
var nums = Math.min(rows.length, selectedTrackNames.length);
//Assign tracks
for (var i = 0; i < nums; i++) {
var row = rows[i];
var trackName = selectedTrackNames[i];
//Select row
var cells = row.children.allItems;
cells[cells.length - 1].popupMenuSelect({
menuPath: [trackName]
});
}
//win.windowClose();
Links
User UID: JdZtw0WY87gOjxGuhI53m3IjCY63
Feedback Key: sffeedback:JdZtw0WY87gOjxGuhI53m3IjCY63:-O5-6SAHUKPLVO52E947
Feedback ZIP: h/HGbVe9a1vc1twsL479YaXntsTQVlxWDc3WuJerppZf7bbGFC51zANE49MgA3MmBULEXUAoACS5SIaGeNd16WXYwK5xsojUD2+a2213GVi+Fh4Rx0ez1LONjXhJxIeWpeVjW9gv9OCG2nnCdOGc6/8reEelQT4nrBSSFOO+y2UdPUbBUrnPtr4yeMVZbzdCfhkBlxSxBag0+cnU/pyqBcWrR86lI0ENAUGokgnHxx6BCjR0j75QwN7XX44v5TCFaPdmIsZCJd76P/D2H04twTBreflDBTpm97oZQlS91+7Gzd6P4t2Tae6vvlMkMIMwlRpHsImx6iB7AL/0OYWt7Q==
- SSoundFlow Bot @soundflowbot
Thanks for posting a question or an issue related to the 'EuControl' package.
This package is made by @chrscheuer. We're auto-tagging them here so that they will hopefully be able to help you. - In reply torandy_matuszewski⬆:Christian Scheuer @chrscheuer2024-09-09 08:12:31.886Z
Hi Randy,
Unfortunately, I no longer have the hardware to test/implement this properly. I'm sure it would be an easy fix for somebody on the forum with SF knowledge who has access to the hardware, so let me move this to the How to section.
- MMyron Nettinga @Myron_Nettinga
Chris, I am also one that this is truly a valuable function. I have been unable to find any fixes on sight. Any insight to if this has been fixed by someone else maybe? It seems everytime I update PT something new breaks. This broke about 1.5 years ago and I am just getting back to see if any updates. Don't see any that fix it. Any help would be greatly appreciated!
Christian Scheuer @chrscheuer2025-05-03 15:57:11.895Z
Thanks! I should be coming back to the office where I have an Artist Mix sometime soon, hopefully, I can take a look.
- LIn reply torandy_matuszewski⬆:Lucas Frisch @Lucas_Frisch
Hi,
Anybody found a way to make this work again? a real time saver a really miss..
Chris Shaw @Chris_Shaw2025-04-09 14:38:35.473Z
I'm not having any issues with this script on my system (Ventura / PT 2024.10.2 / SF 5.10.3)
What error if any are you getting when you run it?- In reply toLucas_Frisch⬆:
Chris Shaw @Chris_Shaw2025-04-09 16:27:21.634Z
If you could share a screen recording of what's happening that would very helpful as I'm not seeing any errors in the SF log.
- LLucas Frisch @Lucas_Frisch
https://drive.google.com/file/d/1It_QuNPGYfEdjG-rFFsqdt5ZzpE_NAwO/view?usp=sharing
( i'm on Sonoma..) PT2024,10,2 SF 5,10,2
- TTorsten Zumhof @Torsten_Zumhof
Same Problem here : Latest Eucon and Pro Tools Version on Sonoma
- In reply toLucas_Frisch⬆:MMyron Nettinga @Myron_Nettinga
agree, it broke about a year ago when upgraded to latest version of PT. I left alone hoping that it would get fixed in an update, no solution. Would be great to get this working again. It is 1 of 2 primary macros I use alot that saves a ton of time. The other macro (delete temp group/create new temp group) is the same scenario. Doesn't work anymore. I am runnning latest software of PT/Eucon/SF with an S3
- LIn reply torandy_matuszewski⬆:Lucas Frisch @Lucas_Frisch
hers my log :
09.04.2025 18:35:26.98 [Backend]: [KeyboardInterfaceController] #Key: shift+f (3) -> Assign Selected Tracks [ck2pyhikp0003im10pui69hiv]
09.04.2025 18:35:26.98 [Backend]: >> Command: Assign Selected Tracks [user:ck2mfhvls00016i107frjysdn:ck1xwq6q40000cd108e2d300r]
09.04.2025 18:35:26.98 [Backend]: [NSRunningApplication (static)] Checking for running apps with bundle 'com.Euphonix.EuControl'
NSArray.ArrayFromHandle count = 109.04.2025 18:35:27.18 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (1235, 373,5)09.04.2025 18:35:27.19 [Backend]: Moving back...
09.04.2025 18:35:27.19 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:27.25 [Backend]: Clicking popup menu element: REV DIAL 2
09.04.2025 18:35:27.32 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (1235, 392,5)09.04.2025 18:35:27.32 [Backend]: Moving back...
09.04.2025 18:35:27.33 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:27.36 [Backend]: Clicking popup menu element: Dial A1
09.04.2025 18:35:27.42 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (1235, 411,5)09.04.2025 18:35:27.43 [Backend]: Moving back...
09.04.2025 18:35:27.44 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:27.48 [Backend]: Clicking popup menu element: Dial A2
09.04.2025 18:35:27.55 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (1235, 430,5)09.04.2025 18:35:27.55 [Backend]: Moving back...
09.04.2025 18:35:27.56 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:27.60 [Backend]: Clicking popup menu element: Dial A3
09.04.2025 18:35:27.67 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (1235, 449,5)09.04.2025 18:35:27.67 [Backend]: Moving back...
09.04.2025 18:35:27.68 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:27.76 [Backend]: Logging error in action (01) ClickPopupMenuAction: Could not find menu item with name: Dial A4
09.04.2025 18:35:27.88 [Backend]: [NSRunningApplication (static)] Checking for running apps with bundle 'com.Euphonix.EuControl'
09.04.2025 18:35:27.89 [Backend]: NSArray.ArrayFromHandle count = 1
09.04.2025 18:35:27.97 [Backend]: Mouse current pos is: (756,74609375, 39,02734375)
Clicking with mouse here: (523, 222)09.04.2025 18:35:27.97 [Backend]: Moving mouse back to: (756,74609375, 39,02734375)
09.04.2025 18:35:27.98 [Backend]: Position is now: (756,74609375, 39,02734375)
09.04.2025 18:35:28.00 [Backend]: Logging error in action (01) PopupMenuSelectAction: Could not click popup menu item
09.04.2025 18:35:28.00 [Backend]: !! Command Error: Assign Selected Tracks [user:ck2mfhvls00016i107frjysdn:ck1xwq6q40000cd108e2d300r]:
Could not click popup menu item (Assign Selected Tracks: Line 29)
Could not find menu item with name: Dial A4<< Command: Assign Selected Tracks [user:ck2mfhvls00016i107frjysdn:ck1xwq6q40000cd108e2d300r]
09.04.2025 18:35:42.71 [Backend]: [SF_FIREBASE_WS]: Sending keep-alive
- RIn reply torandy_matuszewski⬆:randy matuszewski @randy_matuszewski
here's a video. eucon just assigns the first track and stops.
https://drive.google.com/file/d/1OaM_j9MTf1qwyC7zNhx_W39kRgzfdzee/view?usp=drive_link
randy
Chad Wahlbrink @Chad2025-05-03 03:38:59.536Z
@randy_matuszewski, @Lucas_Frisch, @Myron_Nettinga, @Torsten_Zumhof
I believe this is a bug in macOS Sonoma and above. We had similar issues with pop-up menus in Pro Tools when Sonoma was released. You can read more about that and see another example here:
In this case, we can use the same
popupMenuSelectAndWait()
method that @Kitch wrote for this other post to wait for the pop-up menus to be selected appropriately.Try the updated script below. I also uncommented the "win.windowClose()" command at the end of the script to allow the window to close as Randy mentioned wanting.
/** * @param {Object} args * @param {AxElement} args.popupButton * @param {String[]} args.menuPath */ function popupMenuSelectAndWait({ popupButton, menuPath }) { // Wait for the Popup Button popupButton.elementWaitFor(); // Click the Popu Putton to display and get the Popup Menu const popupMenu = popupButton.popupMenuOpenFromElement({ anchor: "TopLeft", // Required to account for possible menu panel overlaps. relativePosition: { x: 5, y: 5 }, // Required to make sure the menu is not being picked from the Popup Button's frame boundaries. }).popupMenu; // Select the Menu Path popupMenu.menuClickPopupMenu({ menuPath }, () => { sf.ui.frontmostApp.appActivateMainWindow(); // If the menu selection fails, activate the app's main window before throwing an error. throw `Failed selecting menu path: ${JSON.stringify(menuPath)}`; }); // Wait for the Popup Menu to no-longer have children in turn confirming that the menu has closed. sf.waitFor({ callback: () => !popupMenu.invalidate().children.first.exists, timeout: 2000, }); } if (!sf.ui.proTools.isRunning) throw `Pro Tools is not running`; sf.ui.proTools.appActivateMainWindow(); sf.ui.proTools.mainWindow.invalidate(); var eucon = sf.ui.app('com.Euphonix.EuControl'); eucon.appActivate(); eucon.getMenuItem("Window", "EuControl Settings").elementClick(); var win = eucon.windows.whoseTitle.is('EuControl Settings').first; win.elementWaitFor(); //Switch to Assign tab win.tabGroups.first.radioButtons.whoseTitle.is('Assign').first.elementClick(); win.tabGroups.first.checkBoxes.whoseTitle.is('Display Application\'s Track Numbers').first.elementWaitFor(); //Clear existing assignments win.tabGroups.first.buttons.whoseTitle.is('Clear All Assignments').first.elementClick(); //Init var table = win.tabGroups.first.scrollAreas.first.tables.first; var rows = table.childrenByRole("AXRow").allItems; var selectedTrackNames = sf.ui.proTools.selectedTrackNames; var nums = Math.min(rows.length, selectedTrackNames.length); //Assign tracks for (var i = 0; i < nums; i++) { var row = rows[i]; var trackName = selectedTrackNames[i]; popupMenuSelectAndWait({ popupButton: row.popupButtons.first, menuPath: [trackName], }) } // Close the Window win.windowClose();
- LLucas Frisch @Lucas_Frisch
Thanks a lot Chad for the explanation and the Fix!
Works on my system perfectly!!( Sonoma , latest pro tools and Eucon)