tell application “DVD Player”
activate
open VIDEO_TS file “Desktop:VIDEO_TS”
set controller visibility to false
set viewer visibility to true
set viewer full screen to true
play dvd
end tell
If I have a VIDEO_TS folder on my Desktop this does not work, nor does any similar script if I have a VIDEO_TS folder in a folder someplace.
USAGE:
open VIDEO_TS: open a VIDEO_TS folder for playing dvd from disk
open VIDEO_TS file specification – file reference to VIDEO_TS folder
'm missing something about how to specify where to look.
Please help!
Thanks!
which is interpreted as open the file called VIDEO_TS on the disk called ‘Desktop’. I’m guessing your disk isn’t called ‘Desktop’.
You see, pathnames either need to include the name of the disk you’re working on or need to be specified as relative to some location on disk.
Consequently, either of the following should work:
open VIDEO_TS file "Macintosh HD:DesktopVIDEO_TS"
(assuming your disk is called “Macintosh HD”), or
open VIDEO_TS file (path to desktop & "VIDEO_TS")
Also be aware that there are two ‘desktop’ folders on your disk. “Macintosh HD:Desktop” is the common desktop for all users, but each user will have their own desktop folder in “Macintosh HD:Users::Desktop” and the file may be in there.
After having been an avid Mac fan for years, I finally decided to venture into the world of AppleScript. I am attempting to write a simple script that will launch DVD Player, open a specific VIDEO_TS movie off of my HD and play it full screen. I’ve been searching the forums and this thread was the most helpful thus far. However, I’m still running into a bit of a snag.
Here is the entire script:
tell application “DVD Player”
activate
open VIDEO_TS file “G4:Users:biblejam:Movies:VIDEO_TS”
play dvd
set viewer full screen to true
end tell
Here’s the problem… running this script in Script Editor while DVD player isn’t launched opens the program and starts playing the movie full screen (exactly as I hoped it would), but script editor gives me an error message indicating:
AppleScript Error
DVD Player got an error: Can’t get the file “G4:Users:biblejam:Movies:VIDEO_TS”.
And if I run the script while DVD player is aleady open, it gives me the same error message but it doesn’t even play the movie. Saving the script as an application and launching it (with DVD player open or closed) produces the same result, error message and no playback.
Any ideas?
~aaron
p.s. I have tons of experience with my Mac but absolutely zero experience with scripting. I’ve been able to figure out bits and pieces by searching on the internet and reading the help files. I used to write programs in AppleSoft BASIC years ago, so I’m not a complete stump. However, I would appreciate layman translation for any scripting jargon until I get my feet a bit wetter than they are. Thanks 10^6!
Model: MDD G4
AppleScript: 1.10
Browser: Safari 412
Operating System: Mac OS X (10.4)
tell application “DVD Player”
activate
open VIDEO_TS alias “G4:Users:biblejam:Movies:VIDEO_TS:”
set viewer full screen to true
play dvd
end tell
tell application “Finder”
close windows
end tell
quit
Hi, all. My problem’s not quite the same, but very similar. I want to be able to pass variables into the “open VIDEO_TS” command, i.e.,
set halt to false
set prefix to “Drive 1:My Stuff:My Movies:”
set suffix to “:VIDEO_TS:”
set choice to “”
tell application “Finder”
set movies to the name of every item of alias prefix
set choice to (choose from list movies with prompt “Pick a movie to watch”)
set themovie to (prefix & choice & suffix) as string
if choice is false then set halt to true
end tell
if halt is false then
tell application “DVD Player”
activate
open VIDEO_TS alias themovie
set viewer full screen to true
play dvd
end tell
end if
All goes well until I get to the “open VIDEO_TS” line. I then get this error: DVD Player got an error: Can’t get alias “Drive 1:My Stuff:My Movies:Shrek 2:VIDEO_TS:”.
Does AppleScript not allow variables to be passed in? I’ve tried forcing the type of themovie (i.e., themovie as alias, etc.), I’ve tried changing “alias” to “file”, “file reference”, and “folder”, all with no luck.
hi all…i am interested in a script that will do the following:
on dvd movie insert
launch dvd player
set volume to 0
set screen to full size
play the feature movie
and loop until told to to stop
basically this is kiosk mode and i know with the new idvd you can create 1 step dvd’s for this. However, i work at a place that has a bunch of old media that we display all at once and i would like to create a set and forget solution. Thanks…here’s what I have so far:
Tell application "DVD Player"
activate
set viewer full screen to true
set audio volume to 0
play dvd
End Tell