AX / D365FO – Electronic Reporting set output file name

By default the name of the electronic reporting output file is made up of :

  • “UserId”+ fixed string “.out”.

We can change this name in a static or dynamic way.

In my case I prefer to set a unique name. For example consisting of :

  • a static prefix (eg. PriceList) + LegalEntity+ execution date / time

Now let’s see how to set a dynamic filename

Open Workspaces > Electronic reporting > Report Configurations

Open your ER Format > Designer

“Add root” > “File”

Give it a unique name (eg.FileName) and click Ok

Now click on edit button of File name property

And edit this formula

CONCATENATE("PriceList_", GetCurrentCompany(), "_",   DATEFORMAT(TODAY(), "yyyyMMdd"))

Where :

  • GetCurrentCompany() returns the Legal Entity name
  • DATEFORMAT(TODAY(), “yyyyMMdd”) returns current date in YYYYMMDD format

You can also do a test of how output should come out by pressing “Test” button

And should be something like that

3 responses to “AX / D365FO – Electronic Reporting set output file name”

  1. James Avatar
    James

    Hi Marco,

    Thank you for the post, as this is something a client of mine wants. They want the File Name to be the Vendor Payment Batch Number.

    So I tried what you suggested, and Generated payments, but sadly it doesn’t default the file name as I thought it would.

    So maybe there is something I am missing.

    Regards
    James

    Like

  2. Klara Calabro Avatar
    Klara Calabro

    Hi Marco,

    thank for sharing your knowledge with us.

    Is there a way how to get file name by inbound format mapping too. The File is as a record in the format mapping but I could not found way how to get the filename in the format mapping. Thank you

    Like

  3. Anders Dahlin Avatar
    Anders Dahlin

    It looks a bit different now but if you select designer, then mapping at the right you can find the file name and set a formula for it at the bottom right:

    Like

Leave a reply to Anders Dahlin Cancel reply