CountryRegionContext.Iso2 Property
The ISO two-letter country code representing the geographic context for the SOAP request and response. String. Optional if the EntityID property is used.
Public Dim Iso2 As String
Member of [Namespace].CountryRegionContext
[C#]
public System.String Iso2
Member of [Namespace].CountryRegionContext
Remarks
- The default Iso2 property value is US (United States).
- If the Iso2 property is passed along with the EntityID property, they must both refer to the same country or region; otherwise, a SOAP fault is returned.
- For a table of MapPoint Web Service Iso2 values, see CountryRegion Entity IDs.
- Finding addresses, finding nearby points of interest, and creating routes are limited to certain countries in valid data sources. The MapPoint Web Service Data Sources and Capabilities table lists the countries or regions in a data source that are valid for performing these functions.
Example
[Visual Basic]
'This example assumes that the service instance
''commonService' has already been created and that
'the MapPoint Web Service namespace has been imported
Dim myUserInfoHeader As New UserInfoHeader()
Dim myContext As New CountryRegionContext()
myContext.Iso2 = "US"
myUserInfoHeader.Context = myContext
commonService.UserInfoHeaderValue = myUserInfoHeader
[C#]
//This example assumes that the service instance
//'commonService' has already been created and that
//the MapPoint Web Service namespace has been imported
UserInfoHeader myUserInfoHeader = new UserInfoHeader();
CountryRegionContext myContext = new CountryRegionContext();
myContext.Iso2 = "US";
myUserInfoHeader.Context = myContext;
commonService.UserInfoHeaderValue = myUserInfoHeader;
See Also
CountryRegionContext Class | CountryRegionContext.EntityID Property | CountryRegion Entity IDs | MapPoint Web Service Data Sources and Capabilities