× Home Blog About Us
Products SimpleImport AddressTools PhoneTools IndustryComplete
Partners Support Careers Contact

Blog

 
Blog > Post

How to: Populate a Regional Data Field Based on a Country, State or ZIP Entry

by Laura Truman Support

Note: Functionality for populating regional data based on a country entry is only available for AddressTools Premium, if you are using AddressTools Free then you can trial our AddressTools Premium application to take advantage of this feature plus many more that it includes.

This example will demonstrate creating a Sales Territory field on the AddressTools Country object that a Lead will then lookup. The same steps can be followed for the AddressTools Country, State and ZIP Code objects provided with the package.

Creating a Custom Text Field on an AddressTools Regional Data Object

The first step is to create a custom text field on the AddressTools Country object.

Navigate to Salesforce Setup | Object Manager | Country | Fields & Relationships | New.

UPDATED Country to field page

Select Text.

Select Next.

Enter a Field Label and Field Name to meet your requirements, in this example, we’ll enter Sales Territory.

Creating AT country no 4

Select Save.

Creating a Formula Field to Lookup the New Field Value

The following section requires regional data lookup fields to be configured within AddressTools. If you have not yet configured lookup fields for your address blocks, see the Configure Lookups section in the AddressTools Premium Installation Guide.

Navigate to Salesforce Setup | Object Manager | Leads | Fields & Relationships | New.

UPDATED leads to fields page

Choose Formula.

Select Continue.

Custom fields no 8

Provide the new field with a Field Label and Field Name (it is recommended to provide a name that matches the field created in the first section of the article).

Custom fields no 9

Choose Text as the return type.

Select Next.

On the formula page select Advanced Formula and then Insert Field.

Creating custom fields no 11.png

You will need to select the field created in the first section.

In this example, we choose Lead > Lead Country Lookup > Sales Territory

Note: your lookup field name may differ from the one in this example.

When highlighted, select Insert.

Custom fields no 12

Select Next and provide visibility to all the necessary profiles.

Select Next.

Ensure the field is added to the desired Page Layout.

Select Save.


Now with the formula field created and on the page layout, when the record is saved with a valid country value, the value from the associated country record will now appear in the lookup field.

Using this article, you can now create Country, State and ZIP Code based formula fields for any additional data you wish to add to the Country, State or ZIP Code data installed with the solution!

Contact Us

If you have any questions in relation to this article, contact us at: support@provenworks.com We will be happy to answer any questions or problems that you may have.