• 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
how to coerce a built-up path?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

how to coerce a built-up path?


  • Subject: how to coerce a built-up path?
  • From: Mark Dawson <email@hidden>
  • Date: Tue, 9 Dec 2003 13:52:29 -0800

How do you coerce a built-up file/path into a file or alias type?

set theFolder to (choose folder with prompt "Pick the folder")
set fromFile to theFolder & "duplicate"
set toBundle to theFolder & bundleName
display dialog theFolder & "--" & fromFile & "--" & toBundle
copyFile (fromFile as file) to (toBundle as file)

When I run the above lines, I get an error, "can't make {alias "backup2:x:output:", "duplicate"} into a file."

When I output (in the dialog), I correctly see "fromFile" path (backup2:x:output:duplicate). The documentation for "Jon's commands" says I "cannot use Finder object references" and must "coerce them to strings or aliases" in order to use them. So either I'm building the file path incorrectly, or I'm coercing them incorrectly

Thanks!

mark
_______________________________________________
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.

  • Follow-Ups:
    • Re: how to coerce a built-up path?
      • From: Bill Cheeseman <email@hidden>
    • Re: how to coerce a built-up path?
      • From: Walter Ian Kaye <email@hidden>
    • Re: how to coerce a built-up path?
      • From: Emmanuel <email@hidden>
  • Prev by Date: Re: Nitroglycerine ([OT] was "Angels" and "Drive-by sig files")
  • Next by Date: RE: Screen capture
  • Previous by thread: Re: Nitroglycerine ([OT] was "Angels" and "Drive-by sig files")
  • Next by thread: Re: how to coerce a built-up path?
  • Index(es):
    • Date
    • Thread