AppleScript를 사용하여 웹 사이트에서 정보를 얻으려고하고 있는데 "예상 줄 끝 등이 있지만 식별자를 발견했습니다." 자바 스크립트getInfoByClass의 간단한 오류입니까?
강조 오류가 Heres는 잘못된 코드의 섹션
to getInputByClass(theClass, num)
tell application "Google Chrome"
set input to do JavaScript "document.getElementsByClassName('" & theClass & "')[" & num & "].innerHTML;" in document 1
end tell
return input
end getInputByClass
나는 또한 도움을
tell application "Google Chrome"
activate
set theScript to "document.getElementsByClassName('" & theClass & "')[" & num & "].innerHTML;"
do JavaScript theScript in current tab of first window
end tell
감사를 사용하여 시도 및 실패!