set theFilename to POSIX file "/Users/iMacThere4iAm/Music/File.mov" as alias
if exists theFilename then
display dialog (theFilename as string) & " exists!"
end if
to clarify: AppleScript works with HFS paths (colon separated) unlike shell scripts which expect POSIX paths (slash separated).
the error in your script occurs, when the file doesn’t exist, the coercion as alias causes the error
You can use this form
try
set theFilename to alias "Leopard:Users:iMacThere4iAm:File.mov"
display dialog theFilename as text & " exists!"
end try
or, machine independent
try
set theFilename to alias ((path to home folder as text) & "File.mov")
display dialog theFilename as text & " exists!"
end try
if you want to use the exist command, you need the help of the Finder or System Events
set theFilename to ((path to home folder as text) & "File.mov")
tell application "Finder"
if exists file theFilename then
display dialog theFilename & " exists!"
end if
end tell