• 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: Script expects quoted text mystery
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Script expects quoted text mystery


  • Subject: Re: Script expects quoted text mystery
  • From: Walter Ian Kaye <email@hidden>
  • Date: Wed, 14 Jan 2004 21:12:03 -0800

At 11:13p -0500 01/14/2004, Gary Lists didst inscribe upon an electronic papyrus:

Gnarlodious wrote [01-14-04 10:22 PM]:

> tell application defaultBrowser to OpenURL "http://www.gnarlodious.com/";
>
> it won't even compile?

Even if you set the variable defaultBrowser to "application \"iCab\"" you
won't have any luck,

Actually, you can't even set a variable to an application process on OS X.
Only to a string, such as the app name or full pathname.

because that phrase is not resolving to an application
process. (I don't know the technical jargon.)

You need to use one of two methods, depending on what you want to tell iCab.
Standard Suite stuff will likely work with some alternative methods, but I
think you'll want to gain access to the whole dictionary, so you need a more
robust method of loading the dictionary.

You can try this method (making X-adjustments as needed):

set creaType to "iCAB"
tell app "Finder" to set myApp to the first process whose ,
creator type is (creaType as <<class type>>) as <<class psn >>
tell myApp
-- now you're cooking with gas
end tell

This is the most reliable that I have found (and use.)

On Mac OS 7/8/9, yes indeedy-doody.
However, <<class psn >> doesn't work in/on/under OS X.
Thus the X-adjustments mean that instead of

tell myApp

you have to settle for

tell application path_to_app_file

Yucky.


You can try the double-tell if you'd like, but I don't think it is as robust
(it may very well be, however.) I'll let you google for that one. ;)

Gary
-- whose mother must have perfected the 'double tell'...

Mother traditional Mac OS? :)


-boo
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Script expects quoted text mystery (From: Gary Lists <email@hidden>)

  • Prev by Date: [OT] Perl calling AppleScript
  • Next by Date: Re: Script expects quoted text mystery
  • Previous by thread: Re: Script expects quoted text mystery
  • Next by thread: Re: Script expects quoted text mystery
  • Index(es):
    • Date
    • Thread