LocalGeoCoderGeoCode Method (OneLineGeoCodeArgs) |
Namespace: Telogis.GeoBase
// Geocode using OneLineGeoCodeArgs argument. Max returned results = 5 GeocodeAddress[] addr = GeoCoder.GeoCode(new Telogis.GeoBase.Geocoding.OneLineGeoCodeArgs() { OneLineAddress = "20 Enterprise, Aliso Viejo, CA", MaxResults = 5, Country = Country.USA }); // 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'
// Create OneLineGeoCodeArgs argument. Max returned results = 5 var OneLineArgs = new Telogis.GeoBase.Geocoding.OneLineGeoCodeArgs() { OneLineAddress = "20 Enterprise, Aliso Viejo, CA", MaxResults = 5, Country = Country.USA }; // Geocode using the arguments GeocodeAddress[] addrArray = GeoCoder.GeoCode(OneLineArgs); // Write out the first address in the array Console.WriteLine("Found address {0}", addrArray[0]); // Prints 'Found address 20 Enterprise, Aliso Viejo, California, 92656, USA'