Benutzer 189756
Gast
Hallo Zusammen
Ich würde gerne mit folgendem Script ein Event in den Calendar schreiben.
Der Eintrag wird zwar erstellt, aber die Datei wird nicht gestartet.
Kann mir jemand weiterhelfen?
Danke sehr für jede Hilfe
Gruss
Peter
mein Script
tell application "Calendar" to activate
tell application "iCalmitEingabefeld" to activate
set theCalendar to "Arztbesuche"
set theFile to POSIX path of (choose file)
makeEvent(theCalendar, theFile)
on makeEvent(theCalendar, theFile)
tell application "Calendar"
tell calendar "Arztbesuche"
set dateVar to the current date
set Datum to text returned of (display dialog ¬
"Aufnahmedatum " buttons {"OK"} ¬
default button "OK" default answer short date string of (current date))
set Tag to text 1 through 2 of Datum
set Monat to text 4 through 5 of Datum
set Jahr to "20" & text 7 through 8 of Datum
set the day of dateVar to Tag
set the month of dateVar to Monat
set the year of dateVar to Jahr
set Zeit to text returned of (display dialog ¬
"Aufnahmestart " buttons {"OK"} ¬
default button "OK" default answer "15:00")
set Stunde to text 1 through 2 of Zeit
set Minute to text 4 through 5 of Zeit
set the hours of dateVar to Stunde
set the minutes of dateVar to Minute
set Datum to dateVar
set StrDatum to Datum as string
display dialog StrDatum
make new event at end with properties ¬
{description:"TV Aufnahme ab Set Top Box", summary:"TVRec", start date
atum, end date
atum + 600}
set nr to number of event
delay 2
set theEvent to event nr
delay 2
tell theEvent
make new open file alarm at end with properties {trigger date
atum + 60, filepath:theFile}
end tell
end tell
end tell
end makeEvent
Ich würde gerne mit folgendem Script ein Event in den Calendar schreiben.
Der Eintrag wird zwar erstellt, aber die Datei wird nicht gestartet.
Kann mir jemand weiterhelfen?
Danke sehr für jede Hilfe
Gruss
Peter
mein Script
tell application "Calendar" to activate
tell application "iCalmitEingabefeld" to activate
set theCalendar to "Arztbesuche"
set theFile to POSIX path of (choose file)
makeEvent(theCalendar, theFile)
on makeEvent(theCalendar, theFile)
tell application "Calendar"
tell calendar "Arztbesuche"
set dateVar to the current date
set Datum to text returned of (display dialog ¬
"Aufnahmedatum " buttons {"OK"} ¬
default button "OK" default answer short date string of (current date))
set Tag to text 1 through 2 of Datum
set Monat to text 4 through 5 of Datum
set Jahr to "20" & text 7 through 8 of Datum
set the day of dateVar to Tag
set the month of dateVar to Monat
set the year of dateVar to Jahr
set Zeit to text returned of (display dialog ¬
"Aufnahmestart " buttons {"OK"} ¬
default button "OK" default answer "15:00")
set Stunde to text 1 through 2 of Zeit
set Minute to text 4 through 5 of Zeit
set the hours of dateVar to Stunde
set the minutes of dateVar to Minute
set Datum to dateVar
set StrDatum to Datum as string
display dialog StrDatum
make new event at end with properties ¬
{description:"TV Aufnahme ab Set Top Box", summary:"TVRec", start date


set nr to number of event
delay 2
set theEvent to event nr
delay 2
tell theEvent
make new open file alarm at end with properties {trigger date

end tell
end tell
end tell
end makeEvent