Click or drag to resize

GeoCoderGeoCode Method (String, Country, Int32)

Verizon Connect Logo
Print this page
Learn more about Verizon Connect GeoBase.
Get information about the latest release
Geocode a string address to one or more GeocodeAddresses, within the given Country.

Namespace:  Telogis.GeoBase
Assembly:  geobase.net (in geobase.net.dll) Version: 4.99.0.0
Syntax
public static GeocodeAddress[] GeoCode(
	string address,
	Country cntry,
	int maxResults
)

Parameters

address
Type: SystemString
Address to find.
cntry
Type: Telogis.GeoBaseCountry
Country to search.
maxResults
Type: SystemInt32
Maximum number of results to return.

Return Value

Type: GeocodeAddress
Zero or more GeocodeAddress results.
Remarks

The geocoder is capable of looking up street intersections when they are specified with the & (ampersand) or @ characters. For example:

18th & placentia, costa mesa18th @ placentia, costa mesa

The address may also contain a latitude longitude pair, for example "34, -117".

Related articles: Geocoding Concept, Map Control Tutorial.

Examples
C#
// Geocode an address and country with a maximum of five results returned
GeocodeAddress[] addr = GeoCoder.GeoCode("20 Enterprise, Aliso Viejo, California", Country.USA, 5);
// Write out the first address in the array
Console.WriteLine("Found address {0}", addr[0]);
// Prints 'Found address 20 Enterprise, Aliso Viejo, California, 92656, USA'
See Also