Can't delete calendar in iCal... [with script this time]
Can't delete calendar in iCal... [with script this time]
- Subject: Can't delete calendar in iCal... [with script this time]
- From: David Crowe <email@hidden>
- Date: Wed, 17 Aug 2005 10:38:59 -0600
Title: Can't delete calendar in iCal... [with script this
time]
The following script runs without errors, and the "display
dialog" shows the expected information ... but no calendars are
deleted!
Can anyone explain why? Or, even better, explain how to make it
work.
RemoveEmptyCalendars()
on RemoveEmptyCalendars()
tell
application
"iCal"
repeat
with aCalendar in every calendar
tell aCalendar
if ((count events) + (count
todos)) ¾ 0 then
display
dialog ("> " &
(name of aCalendar)
as string) & " events: " &
(count events) & ", todos: " &
(count todos) giving up after 1
delete aCalendar
end if
end
tell
end
repeat
end tell
end RemoveEmptyCalendars
Thanks,
David Crowe
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden