Does anyone know how to get TextEdit to open a file from an AppleScript. I tried the logical:
tell application "TextEdit"
open file "Drive Name:Users:username
esktop:testing.rtf"
end tell
But it doesn't work. Tells me that the file doesn't understand the open command. But if I substitute "AppleWorks 6" for the application, it works fine. What gives?
I know this version of TextEdit is scriptable because it uses some sample scripts like the font sampler script.
please help.
sidenote: the smiley in the code is funny, though, isn't it? How do you escape that if you want to use vB code in a post?
tell application "TextEdit"
open file "Drive Name:Users:username

end tell
But it doesn't work. Tells me that the file doesn't understand the open command. But if I substitute "AppleWorks 6" for the application, it works fine. What gives?

please help.
sidenote: the smiley in the code is funny, though, isn't it? How do you escape that if you want to use vB code in a post?