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

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

Decode a Base64 attachment file from XML (PEPPOL BIS 3.0 Invoice) and attach invoice created

(1) ShareShare
ReportReport
Posted on by 41
Hello Team, 
 
I have a requirement to decode a base 64 attachment file in the Peppol bis 3.0 xml invoice file and attach the decoded file to pending vendor invoice created.
 
Please suggest me any reference document for this.
 
1. How to decode the base64 file attachment in XML
2. How to attach the same to pending vendor lines created
 
 
I have the same question (0)
  • Suggested answer
    Monikasree GM Profile Picture
    41 on at
    Decode a Base64 attachment file from XML (PEPPOL BIS 3.0 Invoice) and attach invoice created
    Hello @RudyZhang,
     
    Thank you for the below information.
     
    I have retrieved the Base64 string from XML and I have used the below code to convert the base64 to DocuValueFile and stored the attachment in DocuValue table.
     
    DocuValueFile file = BinData::loadFromBase64(base64File);
     
    Regards,
    Monika
  • Suggested answer
    RudyZhang Profile Picture
    Microsoft Employee on at
    Decode a Base64 attachment file from XML (PEPPOL BIS 3.0 Invoice) and attach invoice created
    Hi,
     
    May I ask if your problem has been solved?
    You can try my solution and contact me if you need any help.
     
     
    Best Regards,
    Rudy Zhang
  • RudyZhang Profile Picture
    Microsoft Employee on at
    Decode a Base64 attachment file from XML (PEPPOL BIS 3.0 Invoice) and attach invoice created
    Hi,
     
    Our search shows that you can use the /Convert.FromBase64String/ method to decode Base64 encoded data.
     
    There is some sample code in the official document at the link below to help you understand and use this method better.
    https://learn.microsoft.com/en-us/dotnet/api/system.convert.frombase64string?view=net-7.0
     
    Additionally, if you are using Dynamics 365 BC you can refer to the following documentation to add attachments to your invoices.
    https://learn.microsoft.com/en-us/dynamics365/business-central/ui-how-add-link-to-record#to-attach-a-file-to-a-purchase-invoice
     
     
     
     
    I hope my answer is helpful to you! If you have any other questions, please feel free to contact me.
     
    Best Regards,
    Rudy Zhang

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Sahan Hasitha Profile Picture

Sahan Hasitha 225

#2
DAnny3211 Profile Picture

DAnny3211 134

#3
Abhilash Warrier Profile Picture

Abhilash Warrier 129 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans