No internet connection
  1. Home
  2. How to

Show All Automation Lanes With Active Automation Only?

By Philip weinrobe @Philip_weinrobe
    2023-06-15 16:08:12.526Z

    Hi Geniuses
    I think some people may have asked about this...but seeing as it's now 2023...maybe someone can figure it out?
    I want to run a script that opens all the automation lane(s) on a selected track(s) that have active automation written in them.
    Can anyone way smarter than me figure out a script for this?
    It would be INCREDIBLE to have for all of us heavy automators

    love
    Philip

    • 4 replies
    1. @Philip_weinrobe, unfortunately, this is still not possible since it requires a move from Avid :/
      It's on a lot of people's wishlist, including mine!

      1. MMartin Pavey @Martin_Pavey
          2023-07-12 22:51:10.538Z

          +1
          Mine too.
          It would be really useful.

        • R
          In reply toPhilip_weinrobe:
          Richard Furch @Richard_Furch
            2025-04-25 17:32:44.721Z

            Now we have the "lanes with automation" option. So maybe now it's possible?

            1. Chris Shaw @Chris_Shaw2025-04-25 22:11:52.728Z2025-04-26 00:27:14.948Z

              Yep.
              This will toggle all lanes that have automation on all selected tracks:

              // Check Pro Tools version
              const ptVersion = sf.ui.proTools.appVersionAsNumber;
              
              if (ptVersion < 20240600) {
                  alert("This command requires Pro Tools 2024.6+");
                  throw 0;
              }
              
              // Activate main window and ensure track is visible
              sf.ui.proTools.appActivateMainWindow();
              
              const trackHeader = sf.ui.proTools.selectedTrackHeaders[0];
              trackHeader.trackScrollToView();
              
              // Locate disclosure triangle for automation
              const disclosureTriangles = trackHeader.children.whoseRole.is("AXDisclosureTriangle");
              const firstDisclosure = disclosureTriangles.first.invalidate();
              
              if (!firstDisclosure.title.value.includes("automation")) {
                  throw "The first selected track has no automation lanes";
              }
              
              // Get automation lanes button and check state
              const automationLanesButton = disclosureTriangles.whoseTitle.is("Show/hide automation lanes").first;
              const isAutomationOpen = automationLanesButton.value.invalidate().value === "Selected";
              
              // Toggle automation lanes accordingly
              if (!isAutomationOpen) {
                  automationLanesButton.popupMenuSelect({
                      isRightClick: true,
                      menuPath: ["lanes with automation"],
                      isShift: true,
                      isOption: true
                  });
              } else {
                  automationLanesButton.mouseClickElement({
                      isOption: true,
                      isShift: true
                  });
              }