Validate GPS location against pre-defined location

Overview

This sample demonstrates a way to validate the surveyor's location against a predefined location of the selected city. 

The general logic is this:

- The surveyor choose a city from a displayed list

- If no valid GPS location is captured, the interview cannot be continued.

- Once there is a valid GPS location, the code compare between the captured location and the pre-defined location of the selected city, and display an error message if the current surveyor's location is more than 20 meters from the pre-defined city location. At this state the interview cannot be continued, until the surveyor will change his location to be 20 meters or less than the pre-defined city location.

- The valid distance can of course be changed to any value needed.

 

To import the attached SRV file, follow this link: http://support.dooblo.net/entries/22388573-How-to-import-a-survey

 

The pre-defined cities and locations can be found in the attached excel file. This file need to be imported to the studio as additional data list and be attached to the survey. Please follow this link to learn more about additional data lists and subject stores: http://support.dooblo.net/entries/22793802-How-to-use-an-excel-file-as-a-data-list-in-a-survey 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.