none
Outlook Add-in addFileAttachmentAsync Issues

    Pertanyaan

  • This is an updated stackoverflow repost: https://stackoverflow.com/questions/49825556/outlook-add-in-addfileattachmentasync-issues?noredirect=1#comment87779584_49825556

    I'm having trouble with a web based outlook add-in when trying to add an attachment through the addFileAttachmentAsync() method. When the user triggers addFileAttachmentAsync() they are getting the error The attachment path is invalid. I'm only having this issue with one domain through Outlook 2016 on a windows machine. If the user opens the add-in in OWA everything works correctly and the attachment is added. Also if I try it on other windows machine of mine it works correctly.

    I had the user test the path to the attachment in a browser and the file was accessible. So it doesn't look like its being blocked by a firewall or anti-virus software. However, when the user attempted to manually add the attachment through the add-in URL it also fails and just states "The operation failed".

    I'm thinking this has to be a configuration issue with their Outlook client, IE settings or OS config. I'm just not to sure which one, anyone have an idea to what may be causing this?

    Environment: Outlook Client Version: Outlook 2016 MSO (16.0.4639.1000) 64-bit

    Attachment File: plain old text (.txt) file

    File Headers:

    < HTTP/2 200 
    < date: Wed, 30 May 2018 00:07:36 GMT
    < content-type: text/plain; charset=UTF-8
    < content-length: 795
    < x-powered-by: Express
    < accept-ranges: bytes
    < cache-control: public, max-age=0
    < last-modified: Wed, 23 May 2018 12:32:25 GMT
    < etag: W/"31b-1638cfc7465"

    Sidenote: This is technically a separate issue but I'm also seeing another domain that is getting "There was an internal format error" but for this domain its only in O356 and not Outlook 2016. Oddly these are the only 2 domain that are experiencing problems, otherwise it works flawlessly. Not expecting an answer on the second issue, just though it might help in narrowing down whats going on.

    30 Mei 2018 0:15

Semua Balasan

  • Hello,

    This forum(Outlook for Developers) is for development issue related to Outlook Object Model and I think your issue is more related to Office Javascript Api. According to the top stick thread on this forum "Post Outlook Add-ins questions to StackOverflow.", I would suggest you continue your issue on stackoverflow, and for the current thread, I would move it to Off-Topic  forum.

    Thanks for understanding,

    Best Regards,

    Terry


    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.

    30 Mei 2018 9:23
  • As i stated: "I'm thinking this has to be a configuration issue with their Outlook client, IE settings or OS config. I'm just not to sure which one, anyone have an idea to what may be causing this?", This question is more related to what settings in outlook would block a text file attachment from being added. The attachment was blocked when it was manually added so its clearly not just OfficeJS and points more to the client itself. I hope this angle is appropriate for this forum.
    30 Mei 2018 16:47