Our support engineers have assembled the top recommended solutions for you.
Microsoft Dynamics AX 2012
Upgrading to Microsoft Dynamics AX 2012
Data Import, Export, and Migration
Microsoft Dynamics AX 2009
Application Object Server (AOS)
Enterprise Portal and Role Centers
SSRS and SSAS Integration
I need to save a PDF file to a field in a new ax custom table.
Which should be the right EDT of this field? Have you any example of the code?
You can use Blobdata EDT, for example. Or same other type based on "container" primitive type.The easiest way is to use BinData class - call loadFile() to get data from file and getData() to convert it to container.
Martin "Goshoom" Dráb | UK/Czech rep. | Goshoom.NET Dev Blog
I know that, but I would know if the blob field could be filled in this way:
blob = binData.getData();
where blob is blobdata and I can be sure that the field contents could be readable
How could I show this field in a form? This is the reason why I need some code as example
At the moment I don't know if the content is readable or not
Sorry Pix, but you really asked about saving and EDT, which is what I answered.
The blob contains binary data representing the PDF file, so you'll need something what understands this binary format, i.e. a PDF viewer. Adobe Reader comes with an ActiveX control (see c:\Program Files (x86)\Common Files\Adobe\Acrobat\ActiveX\) and I've seen it used in Dynamics AX, so I would recommend you to go in this direction.
Perhaps if you provided more detail with regards to the business problem you're trying to address we could provide potential solutions that are closer to what you're looking for.
If you're looking to store a PDF file, you can do so in a container with the methods already mentioned. It sounds like you're ok with this. When you say "show this field in a form", what do you expect to be represented on the screen? Typically you don't see container type fields mapped directly to controls on a form, so I have difficulty imagining what it is you're trying to do.
Other Microsoft Sites
I'm a Customer
I'm a Partner
Follow Microsoft Dynamics