Re: Why is copying a file so hard?
Re: Why is copying a file so hard?
- Subject: Re: Why is copying a file so hard?
- From: has <email@hidden>
- Date: Thu, 23 Jun 2005 14:37:05 +0100
Andrew Pavey wrote:
>>If you'd read the AppleScript documentation you'd know that AppleScript's string literals use backslash as an escape character, and to include a backslash in a string literal you have to escape it first, e.g. "\\".
>Helpful advice, but I've just spent an hour searching Apple's support website for Applescript manuals.
The AppleScript Language Guide is two links away from the main AppleScript page. Here's the relevant section:
http://developer.apple.com/documentation/AppleScript/Conceptual/AppleScriptLangGuide/AppleScript.34.html#26262
You'd be quite justified in complaining it's not nearly as easy to find as it should be (e.g. it should be linked directly from SE's Help menu), or that Apple don't keep it completely up to date (in fact, the language hasn't changed much since 1.3.7, but that's still no excuse for letting it rot). [1] But that's not what you're doing: you're complaining that the language is at fault because it fails to appreciate your random assumptions and blind guesswork. AppleScript is guilty of many sins, but on this occasion it's your understanding of the language that's broken, not the language itself. You might bear that in mind before blaming the language For Absolutely Everything. :p
>I tried dragging the files into the Script Editor window and the resulting paths include "/" instead of ":" and don't include "\\".
I believe that's a general OS X feature, not something specific to SE. If you believe it would be more useful for SE specifically to interpret such drag-n-drops by inserting a pre-formatted alias literal into your source code - which is what you usually want - then file a feature request on it. (e.g. Smile already does this.) It'd be a bit naughty given SE is supposedly a language-agnostic editor, but in practice it's always been heavily biased towards AS so one more AS-ism is unlikely to make much difference.
>Whilst I appreciate the three replies I received, I still think it could be easier. And I still don't have any suggestion as to why the OS X Finder is not recordable when the OS 9 one was.....
Because they're two different applications, with different implementations. And for whatever reason (be it insufficient time, resources, user demand, etc.), Apple didn't implement recordability in the OS X version.
has
[1] Feel free to file requests/complaints with Apple on both of these points, btw. You might also try one of the newer third-party AppleScript books for a fresher, alternative approach to the language.
--
http://freespace.virgin.net/hamish.sanderson/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden