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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Address formats different for countries other than current company

(0) ShareShare
ReportReport
Posted on by

I've been presented a requirement where the client only wants printed addresses to include the country/region ID if said country/region ID is different from the country/region ID of the primary address for the current legal entity in which the current user is working.  This feels like a sufficiently 'obvious' request that I'm hoping it may be covered somewhere in standard AX, but I can't see anything in the Organisation administration > Setup > AddressesAddress setup or Organisation administration > Setup > Global address bookGlobal address book parameters forms that might fit the bill.

My first thought was to modify the LogisticsPostalAddress::formatAddress method to implement this as a customisation, but given that addresses aren't specific to a company/DataArea, that simply doesn't make sense.  Additionally, it makes me more certain that this probably isn't a standard piece of functionality.  Hence, can anyone think of a smarter way to do this than adding a new public static method to the LogisticsPostalAddress table (i.e. formatAddressForInternationalMail) that's pretty similar to formatAddress, but conditionally includes the country/region ID?

*This post is locked for comments

I have the same question (0)
  • Verified answer
    André Arnaud de Calavon Profile Picture
    303,390 Super User 2026 Season 1 on at

    Hi Rich,

    You can try to create a runtime function to remove the Country part or do new format of the complete address in case the address is within the same country as the current legal entity. Before going into this you need to be aware that this will have a minor performance penalty. When it comes to large number of addresses that needs to be used in some process, another approach like creating a new combined address field for internal country might be quicker. But also here a statement is required to determine if the standard address field or the new field must be used.

  • Community Member Profile Picture
    on at

    Thanks André.  Creating a new column in the table for [DomesticAddress] and leaving the existing [Address] column as is will probably be how I approach this.  That way, the LogisticsAddressFormatProcess::run method will still work with the address formats as configured in standard functionality: I'll just have to customise the class to populate the [DomesticAddress] as per [Address], with the exclusion of Country/RegionID.  Whilst this will require a check every time the print address is requested, a helper method for that to compare the address country to the current company country should make everything relatively neat in terms of abstraction.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Sagar Suman Profile Picture

Sagar Suman 2 Super User 2026 Season 1

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans