• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Passing variable from javascript to applescript
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passing variable from javascript to applescript


  • Subject: Re: Passing variable from javascript to applescript
  • From: Chris Swain <email@hidden>
  • Date: Tue, 25 Apr 2006 22:02:24 +0100

Hi,

Thanks Emmanuel, 

Chris

Do check the dictionary: you have to tell what window you're sending "do _javascript_" to:

 [...] do _javascript_ [...] in document 1, or in window 1.

Emmanuel



tell application "Safari"
activate



set the_SMILES to do _javascript_ "var drawing = document.JME.smiles();
  document.form.smi.value = drawing;
  return document.form.smi.value" in document 1



display dialog the_SMILES



end tell
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: scripting Word top copy text - should be simple, but ain't
  • Next by Date: Re: QuarkXPress 4.11 script breaks in 6.5 - Why? (AND: Can anyone explain this?)
  • Previous by thread: Re: Passing variable from javascript to applescript
  • Next by thread: iCal Script
  • Index(es):
    • Date
    • Thread