Unicode text and paths
Unicode text and paths
- Subject: Unicode text and paths
- From: jj <email@hidden>
- Date: Thu, 02 Jun 2005 18:45:21 +0200
Hi all!
Most probably this has been covered before, but I don't know how can I find
something in the archives using "Unicode text" as search term. So, here is
the code:
############################
set someDir to choose folder
try
(someDir as text) & "file"
--> error if path contains Unicode characters (eg, japanese)
on error
tell application "Finder" to (parent of someDir as Unicode text) & ¬
(name of someDir) & ":file"
end try
--> result: "disk:dir:file"
############################
My old "modus operandi" to get a new path was coercing a folder to text,
then adding a new file name; and it still works fine in my machine.
But now I want support for any kind of Unicode text, and the "tell app
Finder" line seems a bit stupid, appart from slow.
So, does it exist a smart workaround for this simple task?
jj
--
http://www.macscripter.net/
http://www.osaxen.com/
_______________________________________________
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