1

I am trying to write a small script that will move all reminders from one list to another. After some experimentation, I have come up with this, that seems to do what I want:

tell application "Reminders"
   set oldList to list "Test1"
   set newList to list "Test2"
   repeat with thisReminder in (get reminders in list "Test1" whose completed is false)
      copy thisReminder to list "Test2"
   end repeat
end tell

Two things puzzles me and which I would like to understand in order to increase my knowledge about AppelScript:

  • If one changes copy to move, then items will disappear from "Test1" but not appear in "Test2". With copy there are in fact moved.
  • If the copy statement uses newList rather than list "Test2", it stops working, then nothing happens.
  • I don't have enough for an Answer, but can confirm I see the same bizarre (and data-destroying!) behavior. I see copy is not listed in the Reminders Dictionary, but if unimplemented, I'd hope it would error out, not just destroy the entries. That and the named list object treatment makes scripting Reminders smell half-baked. – Joel Reid Apr 11 at 18:44

You must log in to answer this question.

Browse other questions tagged .