axaptamicrosoft-dynamicsx++ax

Convert byte array to pdf


I am generating a .pdf file in an asp.net/c# enviroment. Then I convert the file to byte[] and send it to Dynamics AX. Is there a way to convert the byte[] back to .pdf and save it as DocuRef.


Solution

  • If you want to save it as a file and reference it via a DocuRef record then just recreate the file on a network share or something similar via .NET (e.g. using System.IO.FileStream)