Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How do I run a javascript/script within an applescript?



Hi Stan

I tried your variation below but it does not compile for some reason. It 
gives me an error "Expected end of line but found "." What does that mean?

I am using Script editor 2.0 (v43) Applescript 1.9.3

I remember vaguely that this used to run on my machine. Does this require a 
specific scripting addition?

Best, Patrik
   
> tell application "InDesign CS"        do script file "G5:Cleanup.js" 
> language javascript    end tell
> 
> You may also replace the file reference with quoted javascript code:
>     tell application "InDesign CS"
>         do script "// this is a comment
>     var thisString = \"Hello, World.\"" language javascript
>     end tell
> 
> That should get you going down the correct path, so to speak.
> 
> Stan C.
>
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden
Archives: http://lists.apple.com/mailman//archives/applescript-users

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.