osx - what's wrong with my applescript-syntax error: expected "then", etc. but found class name -


tell application "system events" set window_check false repeat until (window_check)     set frontapp name of first application process frontmost true     if frontapp "microsoft outlook"         tell process "microsoft outlook"             if class of front window draft window              --syntax error: expected "then", etc. found class name                 display dialog "draft"                                   set window_check true             end if         end tell     end if end repeat end tell 

when save script, pop error "syntax error: expected "then", etc. found class name" (see comment error location)

what's wrong script?

you have tell outlook, not system events...

tell application "microsoft outlook" return class of front window draft window 

Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -