web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Dynamics 365 Community / Forums / Finance forum / Attaching a file in Ve...
Finance forum

Attaching a file in Vendor invoice attachments using Web service (Snaplogic Integration)

(0) ShareShare
ReportReport
Posted on by 330

Hello Everyone,

I have a requirement wherein i have a vendor invoice pdf file which is stored in sharepoint server which i need to attach to a pending vendor invoice in d365fo we are currently using snaplogic to read the file from sharepoint server and transform the contents into binary data and Rest post operation to push this data into ax.

From AX side i have exposed DourefEntity so when i am trying run the snaplogic Rest post operation using the file operation its failing to load the binary data.

Can anybody help me out to resolve this issue or if there is any other alternative to attach a pdf file in ax using service?

Categories:
  • Suggested answer
    Ludwig Reinhard Profile Picture
    Microsoft Employee on at

    Hi,

    For the pending vendor invoice data there are in total 3 entities available. One of them is for attaching invoice pictures. Maybe you can take a look at that entity and use it.

    Another question is why you save the documents first on share point? You can upload all your invoice information including the attachment, which is automatically stored on share point. That might be another alternative for you.

    Best regards

    Ludwig

  • ShahTanuj Profile Picture
    330 on at

    I have tried with VendorInvoiceDocumentAttachmentEntity but it gives the same error "Binary (object), method constructFromContainer called with invalid parameters"

    Actually we have a third party system which uploads the invoices to the sharepoint folder and we have to pick the invoice from there and insert it into ax as attachments using service.

  • Verified answer
    ShahTanuj Profile Picture
    330 on at

    The issue is resolved now there was some problem with the code as i had to first load the base64 data into the File contents container then load the binary data using Bin class in ax, now  i am able to attach the pdf file in ax using service.

    Thanks 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Finance

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans