Re: How do I change path punctuation?
Re: How do I change path punctuation?
- Subject: Re: How do I change path punctuation?
- From: Paul Berkowitz <email@hidden>
- Date: Mon, 03 Dec 2001 12:10:48 -0800
On 12/3/01 11:49 AM, "John Tuttle" <email@hidden> wrote:
>
Given:
>
>
display dialog "Please select a folder of images." buttons {"Ok"}
>
set imgfolder to (choose folder) as text
>
>
Result "John's HD:slides:html:"
>
>
How do I change the colons in the retrieved text to forward slashes on the
>
fly?
set str to "John's HD:slides:html:"
set {tids, AppleScript's text item delimiters} to {AppleScript's text item
delimiters, {":"}}
set ls to text items of str
set AppleScript's text item delimiters to {"/"}
set str to ls as string -- or "" & ls
set AppleScript's text item delimiters to tids -- should be {""}
str
--> "John's HD/slides:html/"
--
Paul Berkowitz