No internet connection
  1. Home
  2. How to

Bypass a send without scrolling to track.

By Jamison Rabbe @Jamison_Rabbe
    2022-01-20 19:42:05.349Z

    It seems that all commands that bypass/toggle a send require that send to be in view. Is there a way to toggle a send without it being visible. I'd like to enable/disable sends in batches, but dont want to have to scroll to each track I'm altering.

    Thanks in advance.

    Solved in post #5, click to view
    • 7 replies
    1. Hi Jamison

      Unfortunately, the bypass toggle commands need to simulate a "cmd"+mouse-click and this requires the element to be on screen / visible.

      You could also achieve this by using UI automation to open the send output window and then toggle the M (send mute) button in that window. This would include more steps and the send window would flicker open/close, but wouldn't force you to scroll the track to view.

      1. Depending on how you organize your session, if you rearrange your bussing a bit so that the send goes through a separate Aux track that can simply be muted/unmuted, then you could just toggle the mute state of that track, which also doesn't need the track to be in view.

        1. JJamison Rabbe @Jamison_Rabbe
            2022-01-20 20:53:42.171Z

            Ah darn. Ok I guess the flickering send output beats any "scroll to track" option. So its just:

            •open send output
            •mouse click mute button
            •close send output

            ?

            I don't love the aux option just because it would require 44 separate aux tracks.

            Its a complex setup where I'm trying to break record tracks into "groups" in which the tracks bussed to each group also only 'hear' the groups they're bussed to. It requires a send to the chosen "group", but then a send back to the source. So its two sends that need activation per command, and it needs to be able to happen quickly.

            1. samuel henriques @samuel_henriques
                2022-01-20 21:01:21.922Z2022-01-21 09:03:49.128Z

                Hello Jamison,
                Was working on something for you when @chrscheuer came up with the solution, I didn't think about. Thank you!

                Try this and let me know how it goes.

                In this part you define your settings. In this case a list of track names (an array) and send number

                bypassSendToggle(["Audio 1", "Audio 2", "Audio 3", "Audio 4"], 1)
                

                Complete script:

                /**
                * @param {array} trackNames
                * @param {number} sendNumber
                */
                function bypassSendToggle(trackNames, sendNumber) {
                
                    if (sf.ui.proTools.mainTrackOutputWindow.exists) {
                        sf.ui.proTools.mainTrackOutputWindow.getElement("AXCloseButton").elementClick();
                    };
                
                    trackNames.forEach(trackName => {
                        const track = sf.ui.proTools.trackGetByName({ name: trackName }).track
                        track.trackSendToggleShow({ sendNumber })
                        sf.ui.proTools.mainTrackOutputWindow.buttons.whoseTitle.is("Mute").first.elementClick();
                    });
                
                    sf.ui.proTools.mainTrackOutputWindow.getElement("AXCloseButton").elementClick();
                };
                
                sf.ui.proTools.appActivateMainWindow()
                sf.ui.proTools.invalidate()
                
                bypassSendToggle(["Audio 1", "Audio 2", "Audio 3", "Audio 4"], 1)
                
                Reply3 LikesSolution
                1. samuel henriques @samuel_henriques
                    2022-01-20 21:06:42.643Z

                    Just updated, had a mistake.

                    1. JJamison Rabbe @Jamison_Rabbe
                        2022-01-20 21:09:29.431Z

                        Ah this is beautiful and snappy. Thank you! You guys are awesome.

                2. C
                  In reply toJamison_Rabbe:
                  codebrainzero @codebrainzero
                    2024-08-04 03:34:50.236Z

                    How can this be modified to close the send windows after the script is ran?