The meaning of life is to explore the world

Outlook web add-in traps

Posted on By Jason Liu

  1. Cache of the Outlook add-in needs to be cleared before any update of it can apply
    • Reinstall the add-in
    • for /d %d in ("%LOCALAPPDATA%\Microsoft\Office\16.0\Wef\*") do @rmdir /s /q "%d"
    • del /s /f /q /a:h %LOCALAPPDATA%\Packages\Microsoft.Win32WebViewHost_cw5n1h2txyewy\AC\#!123\INetCache\*
    • rmdir /s /q %userprofile%\AppData\Local\Microsoft\Outlook\HubAppFileCache
      References:
      MS docs to clear cache
      Some ways to clear cache
  2. Local storage is not supported well for web add-in on Windows desktop.
    • localStorage has a size up to 10MB for Outlook on web, but not available on Outlook Desktop
    • indexedDB is not defined on Outlook desktop
    • Office.RoamingSettings is available to all Outlook versions but it is limited to 32KB
  3. Errors caused by missing certificate while trying to connect to backend server via HTTPS
    • Error when no cert
      my_image
    • Error when cert has no -ext "EKU=serverAuth" or -dname "CN=localhost"
      my_image my_image
    • Solution:
        Set up the certificate and keystore.jks properly.
        It can use a self-signed cert pointing to localhost.
        The cert must be installed to “Certificates - Local Computer\Trusted Root Certification Authorities”.