AppleScript ist eine Skriptsprache um Programme zu steuern. Das klappt nur soweit, wie das jeweilige Programm AppleScript unterstützt. Das erste Skript soll ein TV-Programm von der Dreambox 7025 über VLC zu starten:

if appIsRunning("VLC") then
    do shell script "open -a VLC"
end if
tell application "VLC"
    activate
    OpenURL "http://192.168.0.150/web/stream.m3u?ref=1%3A0%3A1%3A6DCA%3A44D%3AA401%3AFFFF0000%3A0%3A0%3A0%3A"
    play
end tell

on appIsRunning(appName)
    tell application "System Events" to (name of processes) contains appName
end appIsRunning

 

  One Response to “mein erstes AppleScript”

  1. [...] können. Wer nicht gerne programmiert, kann mit Automator Abläufe per Mausklick erstellen. Mein erstes AppleScript ist auch schon fertig. Posted by Mike at [...]

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

   
© 2011 Mike schreibt Suffusion theme by Sayontan Sinha