Report printed to e-mail

You can easily send a D365FO report in email just by configuring print destination to Email and setting a few properties. You can do the same from code, where you can also set the body. You must create an instance of SrsReportEMailDataContract class, fill it values and pass it to SRSPrintDestinationSettings.parmEMailContract(). Here is an example: …

Continue reading ‘Report printed to e-mail’ »

Printing reports from code in D365FO

A comment below my blog post Printing reports from code in AX2012 asked me to provide an example for D365FO. Here is it. The code is virtually identical. Only writing a file to a shared folder doesn’t make a good sense in cloud, therefore I changed the code to return the file to user for download. …

Continue reading ‘Printing reports from code in D365FO’ »

Dynamics 365 Saturday South Africa

I’m safely back in Prague and I would like to thank everybody who attended Dynamics 365 Saturday in Johannesburg. There were so many of you! And I want to give special thanks to people who did all the work to make the event happen and those who cared of me there. This was my first …

Continue reading ‘Dynamics 365 Saturday South Africa’ »

Weird behaviour after moving a form to another package

I recently had to move a form to another package, because we decided to extract some functionality to its own independent package. I moved files, built both packages and everything looked fine, so I started making changes for a new requirement. But later I noticed something strange in the form. When I opened the form, …

Continue reading ‘Weird behaviour after moving a form to another package’ »

XML response from OData services

If you call OData services in AX 7 (Dynamics 365 for Finance and Operations), you typically get data in JSON format, like this: { "@odata.context":"https://myaxinstance.cloudax.dynamics.com/data/$metadata","value":[ { "name":"ElectronicPaymentTypes","kind":"EntitySet","url":"ElectronicPaymentTypes" },{ "name":"ExpensePaymentDetails","kind":"EntitySet","url":"ExpensePaymentDetails" } … ] } JSON is a simple, lightweight format with good support in many tools, but sometimes you would rather get XML. XML is by …

Continue reading ‘XML response from OData services’ »