• 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: Difficulty Opening a Text File in BBEdit
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Difficulty Opening a Text File in BBEdit


  • Subject: Re: Difficulty Opening a Text File in BBEdit
  • From: "Arthur J. Knapp" <email@hidden>
  • Date: Tue, 27 Aug 2002 15:20:24 -0400

> Date: Tue, 27 Aug 2002 14:16:16 -0400
> Subject: Difficulty Opening a Text File in BBEdit
> From: Sean Mills <email@hidden>

> I'm try to copy a log file to the desktop and then view it in BBEdit, but my
> Mac keeps trying to open it in SimpleText, which wouldn't be too bad, except

> set logPath to (path to preferences as string) & "log.txt"

> tell application "Finder"
> set logCopy to duplicate alias logPath to (path to desktop) replacing yes

logCopy will be a Finder object, (because it is returned from a Finder
command). Coerce it to a normal value:

set logCopy to logCopy as alias

> tell application "BBEdit 6.1"
> open logCopy

One has to maintain a constant vigilance to ensure that only the
Finder works with Finder objects, because nothing else does.


{ Arthur J. Knapp, of <http://www.STELLARViSIONs.com>
a r t h u r @ s t e l l a r v i s i o n s . c o m
}
_______________________________________________
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.

  • Prev by Date: Re: OT: Re: New Address Book in Jaguar 10.2...
  • Next by Date: Re: making a .app script from the command line with osacompile; convert a compiled script to a .app?
  • Previous by thread: Re: Difficulty Opening a Text File in BBEdit
  • Next by thread: Re: Difficulty Opening a Text File in BBEdit
  • Index(es):
    • Date
    • Thread