• 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: why won't this compile?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: why won't this compile?


  • Subject: Re: why won't this compile?
  • From: has <email@hidden>
  • Date: Fri, 28 Dec 2001 21:54:25 +0000

Paul Berkowitz wrote:

>> What am I doing wrong, if anything?

>The construct 'application "Internet Explorer"' is not the same as the
>English words 'application' & "Internet Explorer".

The problem is that the AS compiler doesn't know (how?) to look for the
application dictionary, so cannot identify the application keywords. [Sort
of a Catch-22... the script has to run for the string "Internet Explorer"
to be assigned to the variable 'browser', but the script can't be run until
it's been compiled.]


>So you can't substitute
>a variable. For OS's earlier than 9, you need to compile the script using
>raw codes, without the 'using terms from'. (Or maybe this was introduced in
>OS 8.6, I forget.)

Nope, doesn't work in 8.6. Must be a 9.x thing.

Smile has a feature called 'copy translate' that makes it easy to get the
raw codes. Raw codes ain't pretty, but they'll do the job.

======================================================================

set theURL to "http://www.maccentral.com";
set theWindow to -1 -- top window

set browser to "Internet Explorer"
tell application browser
[LEFT-DOUBLE-CHEVRON]event WWW!OURL[RIGHT-DOUBLE-CHEVRON] theURL
[NO-BREAK]given [LEFT-DOUBLE-CHEVRON]class
[NO-BREAK]WIND[RIGHT-DOUBLE-CHEVRON]:theWindow,
[NO-BREAK][LEFT-DOUBLE-CHEVRON]class FLGS[RIGHT-DOUBLE-CHEVRON]:7
end tell

======================================================================

HTH

has


  • Prev by Date: Re: URL Access Scripting completion
  • Next by Date: Re: why won't this compile?
  • Previous by thread: Re: why won't this compile?
  • Next by thread: Re: why won't this compile?
  • Index(es):
    • Date
    • Thread