I’m fetching some iCal todo items returned as a list. This works peachy and I get a list object that looks like:
{todo 1 of calendar 5 of application "iCal", todo 2 of calendar 5 of application "iCal"}
All good so far. Now I want to set a variable to that todo and I try:
set temp to (todo 1 of calendar 5 of application "iCal")
But this fails. I know this works:
tell application "iCal"
set temp to (todo 1 of calendar 5)
end tell
Is it necessary to break up the return value of (todo 1 of calendar 5 of application “iCal”) and parsing out the calendar name, then reforming it into a tell application block or am I missing some step in using the entire string?
ideally, I just want to do something like this:
repeat with theToDo in todoList
tell theToDo
set dueDate to (get due date) as string
set description to (get description) as string
end tell
end repeat
and so on