• 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: Very Irritating Open Handler
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Very Irritating Open Handler


  • Subject: Re: Very Irritating Open Handler
  • From: Stan Cleveland <email@hidden>
  • Date: Thu, 31 Mar 2011 13:51:03 -0700

On Mar 31, 2011, at 12:54 PM, Luther Fuller wrote:

More ...

The applications Smile, AppleScript Editor and Terminal all exhibit this behavior:

I open a window, then drag & drop a .webloc file named "How SSL Works.webloc" (for example) from my desktop onto the window. The result is the text
"http://www.definityhealth.com/marketing/how_ssl_works.html"
(but it's not enclosed in quotes)

In order to get an alias to this file, I have to type (not drag & drop) ...

set fileAlias to alias "OS_X:Users:lutherfuller:Desktop:How SSL Works.webloc"

which is a valid alias in AppleScript.

Hi Luther,

As an experiment (running 10.6.6), I saved an app with the following code
on open theFiles
 display dialog theFiles as text
end open
then dragged three files on it: a PDF, an Excel doc, and a webloc file. 

The dialog box appeared, but only the PDF and Excel docs were shown in the dialog. The webloc file was not included in theFiles list. (And, coincidentally, the webloc file was NOT opened in Safari!) So even though this kept the webloc from opening, there's still no access to the file itself. Clearly, the 'on open' handler does not treat webloc files as regular files. 

When I dragged three webloc files on the same script, one of them (but not all) opened in Safari. And, as you pointed out, the script essentially dies at that point. I can't figure out what dictates which webloc opens, but it's not the alphabetical order of either their filenames or URLs nor the chronological order of either their creation or modification dates. 

It's all very strange!

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:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Very Irritating Open Handler
      • From: Tommy Bollman <email@hidden>
References: 
 >Very Irritating Open Handler (From: Luther Fuller <email@hidden>)

  • Prev by Date: RE: Mail App - plain text
  • Next by Date: Re: Mail App - plain text
  • Previous by thread: Very Irritating Open Handler
  • Next by thread: Re: Very Irritating Open Handler
  • Index(es):
    • Date
    • Thread