opening hidden files

i can open a hidden file if i have finder showing hidden files. but thats messy.

so how do i script to open one ?

tell application "textedit"
	open ":volumes:ipodtry:ipod_control:device:trainer:workouts:empeds:4H6424A6VSX:lastWorkout.xml"
end tell

in theory this could be any file, but thats the one im looking to open. I imagine you will have to change the code to something you have on your mac, i haven’t gotten to that variable yet.

Model: powerbook last update
AppleScript: 1.10.7
Browser: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8.1) Gecko/20061026 BonEcho/2.0
Operating System: Mac OS X (10.4)

you can do it with a “do shell script” command:

do shell script "open -a /Applications/ /Volumes/ipodtry/ipod_control/device/trainer/workouts/empeds/4H6424A6VSX/lastWorkout.xml"

if you use TextEdit explicit as the target application, you can also write:

do shell script "open -e /Volumes/ipodtry/ipod_control/device/trainer/workouts/empeds/4H6424A6VSX/lastWorkout.xml"

The path must be separated by slashes.
If there is any space character in the path, you must escape it or put the whole path in single quotes like this:

do shell script "open -e '/Volumes/ipodtry/ipod_control/device/trainer/workouts/empeds/4H6424A6VSX/lastWorkout.xml'"