Configure Azure Maps Autocomplete on Dataverse Forms

Azure Maps - Configuration
This article covers how to setup the Azure Maps Autocomplete Control on Microsoft Dataverse Model Driven forms. These steps must be done by an administrator or a user with system configuration privileges.


 

TABLE OF CONTENTS

 

Configure Azure Maps Autocomplete on Model Driven Forms


 

Considerations for this article

To make the documentation simple, we have chosen to use the Account table with the "Address 1" columns as an example. The configuration is similar of other tables and columns, out of the box or custom.
     
  • In the Power Apps Maker Portal, find the solution containing the entities and forms for which you want to configure Express Entry Autocomplete control. 

  • Open the Account table, and find the form you want to use Address Autocomplete
     

  • Open the form you want to edit and click on “Switch to classic” in the command bar     

  • In the classic configuration screen, add the Address Street Line 1 of the form and click on Change Properties in the ribbon to access the Field Properties screen.

  • In the “Display” area, uncheck the “Display label on form” checkbox

  • Next go the Controls Tab and add the control named "Sharp XRM - Azure Maps Autocomplete" and select the devices where you want the control to be displayed. 

    • Once you have selected the control, you need to provide a value for required properties (identified with a * in the table below); all the other properties are not mandatory :


 

PropertyDescriptionField Type

API Configuration Name *

This refers to your API Configuration unique record name.Static Text Value
 
Advanced Setting IDIf you are using Advanced Control Settings, you need to put the Identifier of your Advance Setting record here.Static Text Value
 
Display Address FieldsThe control can display the address fields under the address search control. Set the value to YES to display these fields. This is a legacy feature.

We recommend setting the value to NO and displaying individual address fields yourself. 
Single Line of Text
Street *

Column where you want to store the street address.
 

Single Line of Text
Unit Number

Column where you want to store the Unit or Suite number. 
 

Single Line of Text
City * 

Column where you want to store the city.

Single Line of Text
State * 

Column where you want to store the state or province name.
 

Single Line of Text
Zip / Postal Code

Column where you want to store the postal code.

Note : Azure Maps can return the extended zip codes in the USA (commonly referred to as zip+4). See the Advanced Control Settings section if you need to enable this features.

Single Line of Text
Country * 

Column where you want to store the country. 

Note : the country is defaulted to its long name. If you want an ISO2 or ISO3 format, see the Advanced Control Settings section. 

Single Line of Text
County
 
Column where you want to store the county.
 
Single Line of Text
Full address

Column where you want to store the fully formatted address as a single line of text. Leave empty is you do not need this.

Single Line of Text
Latitude

Column where you want to store the latitude.

Floating Point Number
Longitude

Column where you want to store the longitude.

Floating Point Number
Default Country

When the form is loaded, this country will be selected by default. Enter one country's ISO 3166-1 alpha-2 code (i.e. US, CA, MX, etc.) 
 

Static Text Value
 
Display Countries

List of countries that will be available in the user interface for selection.

Type the countries using their ISO 3166-1 alpha-2 code (i.e. US, CA, MX, etc.). To display more than one country, type them by separating them with a comma "," without blank spaces (i.e. US,CA,MX).
 

Static Text Value
 
Top Countries

These countries will be pinned to the top of the list (most frequently used countries).

Type the countries using their ISO 3166-1 alpha-2 code (i.e. US, CA, MX, etc.). To display more than one country, type them by separating them with a comma "," without blank spaces (i.e. US,CA,MX).

 


 

  • To set a 'Default Country' or 'Top Country', it must first be added in the ‘Display Countries’ property as well.

  • If a country is saved on the address column (by a background process) and it is not configured in the 'Display Countries' property, the data will be saved, but it will no appear in the address control.

Static Text Value

Known Issue with Microsoft Dataverse early version 9.1 and earlier.
There is a known issue with the Power Platform and Dynamics 365 on early 9.1 versions as well as 9.0 : some of the  address field values may not be available for selection as parameters in the form controls - A workaround is described here. You will need to use the XRM Toolbox to achieve this workaround. Alternatively, configuring the control using the "Maker Portal" should provide you with all the compatible values.


 

  • Click OK, save the form and publish it.

  • Open your account and test your control


 

Working with Advanced Settings


 

Advanced Control Settings allow administrators to configure additional parameters for the address autocomplete control. These parameters are useful for organizations that require their state or provinces to be captured in a specific format. For example, if ISO2 country codes are required, it can be specified in the advanced settings. 


 

  • To get started, find the Advanced Settings by navigating to the Address Validation for Power Apps application and select the “Address Control Settings” menu. Click + New to create a new record.

  • Set the required values 

    • Identifier : Unique Identifier of the Setting. This will be used in the control's configuration on the form. 

    • API Type : Azure Maps

  • List of parameters available for Azure Maps:


 

Parameter

Possible ValuesDescription

Include Extended Postal Code

Yes / No

Allows to add the +4 section of the zip code when available.  

By default, it is set to Yes (i.e. if no setting is present, extended postal codes are returned by Express Entry) 

State NameUse Long State Name
Use Short State Name
--> Nevada
--> NV
 

Country Display

Use ISO2 Country Code
Use ISO3 Country Code ***
Use Long Country Name

--> CA
--> CAN
--> Canada
 

  • Advanced Setting Screenshot   


 

Important Note : these parameters are saved on your end-users' local cache. If you make changes to them, they will need to clear their browser cache for them to be reflected in their usage of Express Entry autocomplete in Dataverse.


 

Assign the required security privileges to users


 

Once the configuration is completed, you need to assign the required security roles to your end users to allow them to use the autocomplete controls. Refer to this article for details on how to achieve this.

Was this article helpful?