Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

REST API: Getting sales invoice pdf in different report layout

Posted on by 5

Hi everyone,

when using get pdfDocument, more precisely /pdfDocument/pdfDocumentContent REST API get pdf in layout which is in business central set as first in sequence
pastedimage1676988771976v1.png
Can I somehow force it, using query or something, to use different layout (in this case let's say the second one)? I can't find anything in documentation, using google. I even asked ChatGPT which suggested using query string layout = {name of layout}, but that did not work either.

Thank you very much for any help 

  • Suggested answer
    DAnny3211 Profile Picture
    DAnny3211 9,272 Super User 2024 Season 1 on at
    RE: REST API: Getting sales invoice pdf in different report layout

    hi

    Reading the documentation, I don't think you can do what you want to do

    learn.microsoft.com/.../dynamics_pdfdocument_get

    DAniele

  • Koson Profile Picture
    Koson 5 on at
    RE: REST API: Getting sales invoice pdf in different report layout

    So there is no way to override this behavior, right?

    I am just so baffled that i can't find anybody asking the same question on google :D seems unreal to me.

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: REST API: Getting sales invoice pdf in different report layout

    I am not sure on this, but in this case it will always prefer 1 sequence.

    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

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,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans