Re: AppleScript-Users Digest, Vol 4, Issue 264
Re: AppleScript-Users Digest, Vol 4, Issue 264
- Subject: Re: AppleScript-Users Digest, Vol 4, Issue 264
- From: has <email@hidden>
- Date: Tue, 5 Jun 2007 20:28:17 +0100
Nigel Redmon wrote:
I'm writing a scripting addition.
[...]
Now I'm
trying to go the other way, with a command that accepts data and a
reference to a file that does not yet exist; the command will create
the new file, write the data in the appropriate format, and close the
file. I would expect this file name to come from the user selecting a
file in the standard Mac directory dialog.
This thread really belongs on the applescript-implementors list, but
anyway...
When extracting the 'file reference' parameter from the incoming
Apple event, specify typeFileURL as the desired type in your
AEGetParamDesc call. (Don't use typeFSS as it's obsolete.) The
resulting AEDesc's data handle will contain a 'file:' URL string
which you can (e.g.) convert to a CFURL via CFURLCreateWithBytes.
HTH
has
--
http://appscript.sourceforge.net
http://rb-appscript.rubyforge.org
http://appscript.sourceforge.net/objc-appscript.html
_______________________________________________
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