• 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: Newbie Quark Scripting critique
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Newbie Quark Scripting critique


  • Subject: Re: Newbie Quark Scripting critique
  • From: Shane Stanley <email@hidden>
  • Date: Thu, 24 Oct 2002 08:33:52 +1000

On 24/10/02 3:31 AM +1000, Wallace, William,
email@hidden, wrote:

> My first question is: Is there an easier, more elegant way to get the path
> to the chosen file (excluding the actual filename)? The way I went about it
> here works fine, I guess, but it seems kind of Rube Goldberg-y to me. Have I
> missed the obvious?

Try this:

set theFile to choose file with prompt "pick a file... any file."
set thePath to theFile as string
set oldTIDs to AppleScript's text item delimiters
set AppleScript's text item delimiters to ":"
set pathToFile to (text from character 1 to text item -2 of thePath) & ":"
set AppleScript's text item delimiters to oldTIDs
tell application "Finder"
if not (exists folder (pathToFile & "EPSfiles")) then

>
> Second question: I seem to recall there being a debate about nesting Tell
> blocks like I have them. Was any consensus reached? Is this bad form? Am I
> playing with fire here?

It's fine like it is.

> PS Does anybody else find it really annoying that Quark feels the need to
> launch itself when you open its dictionary in Script Editor, or if you
> compile a script that references the Quark XPress application? Is it just
> me?

Well, it can be annoying, but it's all in a good cause. QXP has a dynamic
dictionary -- what appears can depend on what XTensions are loaded. This is
a good thing; otherwise XTensions couldn't be scriptable.

--
Shane Stanley, email@hidden
_______________________________________________
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: Scriptable compression software...
  • Next by Date: Re: test a range of numbers
  • Previous by thread: RE: Newbie Quark Scripting critique
  • Next by thread: RE: Newbie Quark Scripting critique
  • Index(es):
    • Date
    • Thread