Title says it all:
I have friend who wanted an AppleScript to change the extension of certain types of files:
He has File Vault enabled - I don't.
The Script works for me, but not for him.
The following code is the problem:
Code:
to changeToPDF(added_items)
tell application "Finder"
repeat with aFile in added_items
display dialog ("You have chosen file: " & aFile) buttons {"OK"} default button 1 giving up after 2
if name of file aFile contains {".aspx"} then
set theDate to (current date)
-- Make the time suitable for a file name (replace ":" with ".")
set timeText to time string of theDate
etc......
the line:
Code:
if name of file aFile contains {".aspx"} then
fails on the FV-enabled machine with the error:
"can't make name of item 1 of {alias "willbank:Downloads:Control.3.aspx"} into string"
Am I doing something wrong - or is this a bug?
Someone else seems to have the same problem:
http://macslash.org/AskMacSlash/03/10/26/1848225.shtml (search for "script")