POST
Fixing the Outlook-to-OmniFocus Script
Here’s how to fix the breakage caused by one of the recent updates to Microsoft Outlook in the Outlook-to-OmniFocus AppleScript included with my SendToOmniFocus spoon.
One of the recent updates to Microsoft Outlook broke the Outlook-to-OmniFocus AppleScript (courtesy of Veritrope) included with my SendToOmniFocus spoon. I’m not sure which precise version introduced the breaking change, I’m currently at version “15.39 (170905)”, and the breakage started one or two updates ago. After some investigation, I found the cause — it seems Outlook AppleScript objects no longer have a “properties” field which contains things like “subject”, “content”, etc., rather their properties can be accessed directly on the object.
I have submitted a pull-request for the
fix, but if you want
to apply it right away, just change the following line in
~/.hammerspoon/Spoons/SendToOmniFocus.spoon/scripts/outlook-to-omnifocus.applescript
:
set theProps to (properties of selectedItem)
to the following:
try
set theProps to (properties of selectedItem)
on error
set theProps to selectedItem
end try
This tries the old behavior, and upon failure uses the new one.
- Tags:
- hammerspoon
- howto
- mac
- outlook
- applescript
- Related:
- August 2020 release of "Learning Hammerspoon" is out!
- Automating Leanpub book publishing with Hammerspoon and CircleCI
- New release of "Learning Hammerspoon" is out!
- First release of "Learning Hammerspoon"
- My Hammerspoon Configuration, With Commentary
- Just Enough Lua to Be Productive in Hammerspoon, Part 2
- Just Enough Lua to Be Productive in Hammerspoon, Part 1
- Using Spoons in Hammerspoon
- Getting Started With Hammerspoon