Register  |  Login   Search
ThinkGeo - GPS Tracking and Mapping Solutions  |  Home  |  Cygnus Track  |  Developer Community
 
LivePerson Chat

Discussion Forums

The online community for users of Map Suite GIS components

ReverseGeoCode
Last Post 09-26-2007 03:38 PM by ThinkGeo. 1 Replies.
Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
DustinUser is Offline
Level 1
Level 1
Posts:3

--
09-18-2007 02:38 PM
I am having a bit of difficulty using the ReverseGeoCode. I am looking for the nearest address to a location. Specifically:

-117.995855
33.802873

In my application and the GeoCode USA 2.0 sample file, a ReverseGeoCode returns an error of:
"Index was outside the bounds of the array."

The more detailed info from my application yields

"System.IndexOutOfRangeException: Index was outside the bounds of the array.
at MapSuite.GeoCodeUSA.x02b56011810c316c.xcd2962740f926d7d(xfbfae26f54c8fc2d x06d16492686dcc07, Double x58316dde3396e982)
at MapSuite.GeoCodeUSA.x02b56011810c316c.x659643111e13b43b(Double xad26a7203634de8e, Double x3f230538ea01aa0e, Double xd2f68ee6f47e9dfb, xfbfae26f54c8fc2d x06d16492686dcc07)
at MapSuite.GeoCodeUSA.x02b56011810c316c.x52a275594b9885ea(Double xad26a7203634de8e, Double x3f230538ea01aa0e, Double xd2f68ee6f47e9dfb, Double xad987153278da131, Double x123c3e3ed6e25861, xfbfae26f54c8fc2d& x06d16492686dcc07)
at MapSuite.GeoCodeUSA.x02b56011810c316c.xd9ae9411a7f4d913(Double xad26a7203634de8e, Double x3f230538ea01aa0e, Double x95fcc33c84c043c8, Double xad7c72f15925da2a, xfbfae26f54c8fc2d& x06d16492686dcc07)
at MapSuite.GeoCodeUSA.x02b56011810c316c.ReverseGeoCode(Double TargetLat, Double TargetLong)
at MapSuite.GeoCodeUSA.GeoCodeEngine.ReverseGeoCode(Double Longitude, Double Latitude, MapUnits DistanceUnit)
at Raptor.GPSInfo.get_NearestAddress() in C:\Projects\Raptor\RaptorClasses\GPSReader.cs:line 117"

Obviously "C:\Projects\Raptor\RaptorClasses\GPSReader.cs" is my file, the rest is clearly an obfuscated GeoCode stack trace.

Basically, GeoCode found no result to return, probably tried to return [0] or something and errored out. Changing the coordinates to something like the following works:

-117.995
33.80

That is clearly not the nearest address to my original coordinates. I have also found that I can brute force a nearest address by incrementing/decrementing the coordinates until I achieve a result. Since this relies on continual exceptions, it is dog-slow.

All of my GPS coordinates will be in the street and never in the exact location of a street address. How can I find the nearest address(es)?
ThinkGeoUser is Offline
MVP
MVP
Posts:1594
Avatar

--
09-26-2007 03:38 PM

dmakintosh,

Thanks for you post!

Using our Geocode USA online demo I was able to return an address for the coordinates that you provided: 11030 Cedar Street, Stanton, CA.

Are you using the Geocode USA 2.1 version or the 2.0 version?

ThinkGeo Support

You are not authorized to post a reply.

Active Forums 4.1