Skip to main content

Posts

Showing posts with the label How to get the address field of customer in a single line in Report or form in axapta

How to get the address of customer in a single line in Report in MSD axapta

To get the address field of customer in a single line in Report or form in axapta you can get hints by following code. DirPartyId partyId; DirPartyAddressRelationship dirPartyAddressRelationship; DirPartyAddressRelationshipMapping dirPartyAddressRelationshipMapping; Address address; str resultAddress; ; partyId = DirPartyTable::find(CustTable::find('1101').PartyId).PartyId; select dirPartyAddressRelationship where dirPartyAddressRelationship.PartyId == partyId; select dirPartyAddressRelationshipMapping where dirPartyAddressRelationshipMapping.PartyAddressRelationshipRecId == dirPartyAddressRelationship.RecId; select address where address.dataAreaId == dirPartyAddressRelationshipMapping.RefCompanyId && address.RecId == dirPartyAddressRelationshipMapping.AddressRecId; resultAddress = address.Street+" "+address.City+", "+address.State+" "+address.ZipCode+" "+address.CountryRegionId; ...