Action
 Add Single Reminder
Add Single Reminder
                  
        Posted by @nahumck,
    Last update
    about 5 years ago
      - Unlisted
    Create a single task to Reminders with a note to a specific list from a prompt (no draft required).
Steps
- 
    script// Single Task to Reminders /*--- Lists ---*/ var names = ReminderList.getAllReminderLists(); let lists = names.map(name => name.title); lists = lists.sort(); // if you would like to target specific lists, comment out the above and use the below syntax //var lists = ["Inbox","Personal","Home","Health","Finance"];
- 
    script/*--- Prompt ---*/ var p = Prompt.create(); p.title = "Select Date"; p.addTextField("title", "Title", "", {"placeholder":"Enter Task","autocapitalization":"words","wantsFocus":true}); p.addSelect("list", "List", lists, ["Inbox"], false); p.addButton("Send to Reminders"); var con = p.show(); var title = p.fieldValues["title"]; var list = p.fieldValues["list"];
- 
    script/*--- Create Task in Reminders ---*/ if (con) { var list = ReminderList.findOrCreate(list) var reminder = list.createReminder(); reminder.title = title; reminder.update(); } else { context.cancel(); }
Options
- 
  After Success Nothing Notification Error Log Level Error 
  Items available in the Drafts Directory are uploaded by community members. Use appropriate caution reviewing downloaded items before use.