none
Outlook VSTO add-in that interacts with the emails and attachments RRS feed

  • Question

  • Since VSTO Is the preferred way to create add-ins on modern Outlook, I was wondering if it's possible to access emails and their attachments from such an add-in? To my understanding, VSTO, being a sandboxed web application, is very limited.

    Basically I need to allow the user to upload (archive) outlook messages and attachments to a remote server, by dragging-and-dropping them onto my add-in pane.

    Is such interaction possible by only using pure VSTO (web) apis, without using native .COM add-in APIs? Is it possible to do anything like that on Outlook for Mac, that supports only VSTO, and no VBA/.COM?

    Thanks for help!




    • Edited by RickDawson Friday, July 14, 2017 10:17 AM
    Friday, July 14, 2017 9:42 AM

All replies

  • VSTO is a wrapper around the COM based (_IDTExtensibility2 interface) addin technology. It is not for the Web addins.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Friday, July 14, 2017 3:03 PM
  • Thanks Dmitry, yes, I meant a web add-in, as this is the only type supported by Outlook for Mac 2016.

    Still the question remains: is it possible to access attachments and all emails from such addin?

    Basically I am trying to be able to let the user drag his emails or attachments on my addin "view".

    (Please let me know if this is the wrong place to ask such questions)

    Thank you

    Friday, July 14, 2017 7:14 PM
  • Thanks Dmitry, yes, I meant a web add-in, as this is the only type supported by Outlook for Mac 2016.

    I have no idea what a web add-in for Mac is.  But I wanted to let you know that MAYBE you can achieve what you want another way.  This at least works with native applications.

    You can create your own user interface in OSX or Windows and have this user interface listen for drag and drops.  When your user interface receives a drop then check to see what it is that was dropped and maybe you will be able to tell it has something to do with Outlook.  Once you know it is something from Outlook you then get the currently selected item and do with it what you want.

    Once again this might not be useful for you but maybe it might help you to think about things differently.

    Saturday, July 15, 2017 6:00 AM
  • Thanks donky for your reply. Yes i was considering having a separate process that acts as a companion to the add-in (although it is making the whole addin unnatural and complicated), but i was wondering if it's possible to do via native addin api... Basically web addins (the only addin type supported by outlook for mac) are javascript applications that are run by a sandboxed embedded web browser: https://docs.microsoft.com/en-us/outlook/add-ins/
    Saturday, July 15, 2017 5:49 PM
  • Probably, but I don't know much about web adins.

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Saturday, July 15, 2017 7:03 PM
  • Basically I need to allow the user to upload (archive) outlook messages and attachments to a remote server, by dragging-and-dropping them onto my add-in pane.

    Hello,

    AFAIK, Office JavaScript API does not provide any methods to do that. Office JavaScript API works for one item. We could get its properties but it is impossible to drag/drop the item onto the pane.

    To work with mailitem folder, you could use Outlook Mail REST API reference.

    If you have any issues related to Outlook REST API, please post on https://social.msdn.microsoft.com/Forums/office/en-US/home?forum=Office365forDevelopers

    Regards,

    Celeste


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, July 17, 2017 8:48 AM
    Moderator
  • Dear Rick

    We have great success using the Microsoft Graph API's to access and manage all the data available in Outlook within our Addins.

    The Graph APIs are a more comprehensive set of REST tools that allow you to access most of the data in the cloud including the Outlook information.  When we combine the Graph with MSAL authentication (using Microsoft.Identity.Client) it's a great solution to do all our work.

    We have some VSTO addins that do drag and drop and I am looking into making a web app with that same functionality and look and feel.  Feel free to contact me using this link

    There you can schedule an online session to meet with me.

    Thanks

    Don

    DeCarlo Software | 412-945-0063  www.decarlosoftware.com | LinkedIN |   Flipboard



    Monday, July 17, 2017 5:46 PM