Copying the address
Addresses are related to the Master Data of the type Person that we discussed in Chapter 2, Architectural Patterns.
In Microsoft Dynamics NAV, the address information is synchronized between the Contact table and their related Customer, Vendor, and Bank Account records.
Tip
The synchronization is described in Chapter 2, Application Design, of the Microsoft Dynamics NAV 2013 book.
Note
An explanation of how the Customer and Vendors are linked to a Contact is available at http://www.olofsimren.com/connect-a-customer-with-a-vendor/.
When addresses are used in Documents, the values are copied from Master Data or the source document. When the address changes at the source, the inherited values are not updated.
The following code snippet, taken from the Sales Header table, shows how the data is copied from one record to another:
Bill-to Customer No. - OnValidate ()\ … GetCust("Bill-to Customer No."); … "Bill-to Customer Template Code"...