◆ LocationFromAddress() [1/2]

static int LocationFromAddress ( out SError  Error,
out LONGPOSITION  Location,
string  strAddress,
bool  bPostal,
bool  bValueMatch,
Int32  MaxTime 

The function returns location corresponding to taken address.

ErrorAdditional error information returned from Drive.
LocationLocation corresponding to taken address.
strAddressAddress in "ISO,city/ ZIP,street,house number" format. If address is in "ISO,city/ZIP,street,street" format, function will return coordinates of intersection
bPostalFlag determining whether second address parameter represents city or ZIP code.
true - ZIP code.
false - City.
bValueMatchFlag determining whether the result will be the exact match or the best value match (true for fuzzy search of address)
MaxTimeMaximum time (in milliseconds) function can take. If MaxTime=0 function execution is not time limited.
1 if successful, other value otherwise.

Address parameter house number is optional. If you do not want to fill it write address like this:

Second address parameter can represent city name or ZIP code.

See Coordinates conversion section in TROUBLESHOOTING page.
The list of ISO codes can be found at http://userpage.chemie.fu-berlin.de/diverse/doc/ISO_3166.html.

ISO code of United States of America consists of character "U" plus code of state. E.g New York has ISO code UNY. Indian states ISO codes can be found at http://devforum.sygic.com/viewtopic.php?f=15&t=2925&p=3646&hilit=I01&sid=354efb86bb92dc0dcdfcc1bb8d656c20#p3646

Possible error codes returned from Drive are:

  • 0 - Function not succeeded.
  • 1 - Function succeeded.
  • 2 - Drive not succeeded.
  • 3 - Function reached timeout.

References SError.SizeOf().

Referenced by CApplicationAPI.LocationFromAddress().