How to select a tab in iTerm2 via AppleScript I am quite a startet with iTerm2 and AppleScript, and can not find a way to let one of my 3 opened tabs get selected via an AppleScript. I have no problem to create a new tab and to select it, but I found nowhere a solution to activate/select an opened tab.
[iTerm2 Build 3.2.9]
Thanks a lot for the help.
Vincent
Yep, I could find online a way to do it. Perhaps there is a better solution, but this works perfectly for me.

tell current window
        set foundProfile to false
       repeat with aTab in tabs
            set profName to profile name of current session of aTab
            if profName is "XXXXX" then
                select aTab
                set foundProfile to true
                exit repeat
            end if
        end repeat
        if not foundProfile then
            create tab with profile "XXXXX"
        end if