在Applescript中添加Javascript以存储元素值

时间:2019-01-09 03:57:14

标签: javascript applescript accessibility voiceover

我正在尝试在Apple Script中添加一些JavaScript以存储元素值,在元素之间进行制表,当它到达第一个元素时,它将停止,然后再次制表到第一个元素。以下是我正在创建的代码段。我是Apple Script的新手,因此很容易被入侵:

激活应用程序“ Google Chrome” 告诉应用程序“ Finder”     将savePath设置为(桌面文件夹的路径为文本)和“ record.m4a”     告诉应用程序“ QuickTime Player”         启用         将doku设置为新的录音         启动Doku         延迟4         告诉应用程序“ VoiceOver”激活

    tell application "Google Chrome" to open location "https://www.google.com"

    delay 10

    repeat 9 times

        tell application "System Events"

            delay 13

            keystroke tab

        end tell


    end repeat
    stop
    close

    tell application "VoiceOver" to quit
    stop doku
    set newDoc to last item of (documents whose name contains "Untitled")
    export newDoc in file savePath using settings preset "Audio Only"
end tell

结束告诉

0 个答案:

没有答案