StreetsByName
 

StreetsByName

Definition

PartialAddress[] StreetsByName ( string username, string password, AddressCaptureLicence licence, string locality, string street )

Description:

Finds a list of streets that match the requested street name within towns or villages matching the locality name.

This method is equivelant to calling the LocalitiesByName method to retrieve a list of all towns or villages that match the locality name, then calling StreetsByLocalityKey for each of the returned towns or villages to find the requested street. However, this method provides much better performance than making these repeated calls. See the documentation for the LocalitiesByName and StreetsByLocalityKey methods for further details.

View all Postcode Lookup Methods

Code Samples

Language:

<!-- Import the Integr8 Ajax API -->
<!-- NOTE: Get your own API key to use in the following script tag from: -->
<!-- http://www.data-8.co.uk/integr8/Admin/Ajax.aspx -->
<script src="http://webservices.data-8.co.uk/Javascript/Loader.ashx?key=your-api-key" type="text/javascript">
</script>

<script type="text/javascript">

function loadIntegr8() {
  // Load the AddressCapture Integr8 service
  data8.load('AddressCapture');
}

function StreetsByName(licence, locality, street) {
  /// <param name="licence">string. One of the following values: WebServerFull, WebClickFull, WebClickThoroughfare, InternalUserFull, InternalUserThoroughfare, SmallUserFull, SmallUserThoroughfare, Lookup, InternalServerFull, InternalServerThoroughfare, FreeTrial, FreeTrialThoroughfare</param>
  /// <param name="locality">string</param>
  /// <param name="street">string</param>
  var addresscapture = new data8.addresscapture();
  
  addresscapture.streetsbyname(
    licence,
    locality,
    street,
    null,
    showStreetsByNameResult
  );
}

function showStreetsByNameResult(result) {
  // Check that the call succeeded, and show the error message if there was a problem.
  if (!result.Status.Success) {
    alert('Error: ' + result.Status.ErrorMessage);
  }
  else {
    // TODO: Process method results here.
    // Results can be extracted from the following fields:
    // result.Results
    //   Contains an array of addresses or partial address details that match the query.
    //   A human-readable description of each item in the array is available in the Description field,
    //   and an identifier to be passed to other methods is available in the ID field.
  }
}

loadIntegr8();

</script>
Skip Navigation Links
Request handled by server S2 for client 38.107.179.217 at 08/02/2012 04:00:49