Guest User

Untitled

a guest
Jan 18th, 2019
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. // get a handle of Outlook App and enable standard additions
  2. outlook = Application("Microsoft Outlook");
  3. outlook.includeStandardAdditions = true
  4.  
  5. //get the first selected message
  6. selectedMessage = outlook.selectedObjects()[0];
  7.  
  8. //copy message id to clipboard
  9. outlook.setTheClipboardTo("" + selectedMessage.id())
  10.  
  11. // this part is for future
  12. //todoist = Application("Todoist");
  13. //todoist.activate();
  14.  
  15. // open message by the id retrieved from clipboard
  16. outlook.open(outlook.incomingMessages.byId(outlook.theClipboard()))
Add Comment
Please, Sign In to add comment