Reverse Geocoding Field always Blank

565
2
11-05-2020 03:07 PM
DarrylHilton
New Contributor III

Hi

I have read https://community.esri.com/groups/survey123/blog/2018/07/06/understanding-reverse-geocoding-in-surve... 

From this I have derived the expression:

pulldata("@geopoint",${location},"reversegeocode.address.Address","URL OF MY LOCATOR SERVICE")

Which I have placed in the calculation field of a multiline text element just after a geopoint element called location.

I can reverse geocode the rest end point to get a result in json, the start of which looks like this:

{
   "address":{
      "Address":"62 BROUGHTON ROAD, DONCASTER, DN4 7HN",
      "LOCATOR_ENVELOPE":"461061,400659,461061,400659",
      "LOCATOR_POINT":"461061,400659",
      "LOCATOR_DESCRIPTION":"62 BROUGHTON ROAD, DONCASTER, DN4 7HN",
      ...

So I don't understand why I am getting nothing at all. 

What am I doing wrong in order to get the Address populating into my text field?

UPDATE: I have managed to get an address populating the field but only when I have search for an address and select that address from the locator search. If I put a point on the map my field remains blank. Is there a default search radius that can be increased that is causing the issue?

0 Kudos
2 Replies
ZacharySutherby
Esri Regular Contributor

Hello Darryl Hilton‌, 

I don't see anything wrong with the syntax you provided. Is the Geocode Service shared publicly and not published to a WebGIS Organization you are logged into with Connect? What may be happening is Survey123 could be passing along your log in token to the service and the service may be rejecting it. For example if your locator is on a standalone ArcGIS Server and you are signed in with ArcGIS Online credentials the Geocode Service on the standalone server may be rejecting the ArcGIS Online token. 

The best way to tell what is going on is to download a program called Fiddler (or any other web debugging proxy), configure it to capture web traffic in your environment, and see what Survey123 is sending to the service and what the service is returning. Please feel free to reach out to Esri Technical Support and they will be able to assist with debugging the web traffic. A potentially easier workflow that configuring Fiddler would be to see what error's are in the Survey123 diagnostic logs as any errors returned by the server should show up in the logs. 

Thank you, 

Zach

Thank you,
Zach
0 Kudos
dedgar_polk
New Contributor II

I'm am having this problem too.  Mine was working and then just stopped with nothing changing on my end.  I'm using iOS.

0 Kudos