Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics AX (Archived)

How to send the pdf file using AIF service

Posted on by Microsoft Employee

Please let me know to create a AIF service to send a PDF file to third party application.

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: How to send the pdf file using AIF service

    Thanks Nikolaos Mäenpää. its working fine for me.

  • Suggested answer
    nmaenpaa Profile Picture
    nmaenpaa 101,156 on at
    RE: How to send the pdf file using AIF service in AX2012

    Are you sure you want to use AIF? Could you provide more information about your requirement?

    This blog shows you how to encode/decode files to base64 format, which you can then include as text in an xml file: devblog.sertanyaman.com/.../using-base64-for-file-transfer-in-ax-2012

    AIF is always based on AX tables and queries, so you need to create an AIF interface that is based on a query. Then you can create a virtual field in your XML field and put the base64 encoded PDF there.

    For example, if your AIF interface uses CustInvoiceJour as a data source, you can add a new parm method in axCustInvoiceJour class, and write your code there, to attach the invoice in PDF format. The receiving party of this file must then decode the base64 string back to PDF.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans