Get Customer, Vendor& Company Addresses in AX 2012

 Get Customer,  Vendor& Company Addresses in AX 2012

//Get Customer/Vendor Address by Id & Current Comapny Address
//By replacing the CustTable with the VendTable we will get the address of Vendor
static void Job85(Args _args)
    CustTable custTable;
    str       description,address,completeaddress;
    custTable = CustTable::find('L0115');
    description = DirParty::primaryPostalAddress(custTable.Party).displayLocationDescription();
    address = DirParty::primaryPostalAddress(custTable.Party).Address;
    completeaddress = strFmt("%1,%2",description,address);
    //Get the Current Company Address

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s