I'm with some problems using the epi info 7. when I try to use the template geolocation I drag to the canvas area of work and the field is blank. How can I get the "get coordenates" button. Latitude And longitude are number or text files, pattern ? ##.## ??

Views: 532


Replies to This Discussion

Hello Dr. Camara,

First I tried to create a form with Epi Info 7 ( template for "Geo_Location" -- but like you, I was unable to get any latitude and longitude by clicking the command button.

I created another example that works (see attached). The difference is the address field is single line TextBox (not Multiline), and entered number masks for latitude and longitude as: "####.#############"

It seems like Epi Info 7 does not display the full precision of the latitude and longitude values, but truncates them to 4 decimal places.  For example, longitude -077.0386962890625 returned by the geocoding service and entered into the form field is actually stored in the Access mdb database with this precision, but the number is displayed on the Epi Info 7 screen as: -077.0387000000000

Perhaps Epi info Helpdesk can explain better how to use the template "Geo_Location".

Have a nice day!

Roy Ing


I got to check out the code to generate code button "Get coordenates," wrote the code but the button does not work. It like as a geocode function feature.
My code is:
It´s my test of geocode feature
Field coordenadas
      GEOCODE endereco , Latitude1 , Longitude1
Endereco a multiline text Field
Latitude1 and longitude1  numeric Field without pattern
Coordenadas is a button field
The check code I saw was:
 Check Code copied from Geo_Location.xml sample template.
Field GetCoordinates
      GEOCODE Address , Latitude , Longitude
I use the template feature, I get the code, I get the fields hidden, but i can´t see them on my canvas form screen.

this imagem i what i get with geo_code template. It is to big !!!

As I said I figure out how is the check code click comand.

I use

1600 pennsylvania avenue, Washington DC  It is ok to find geocoordenates, but with other address in portuguese it can´t find coordenates.

Like Avenida Itália, 1848, Ipatinga, Brasil

Maybe there are some kind of special string to retrieve maps address or we have to setup another map server with portuguese string search!!


leave the pattern blank


try this

Command Button and GeoCoding


Now we will do something that is some what complex but if we take it one step at a time we will be okay.


Epi Info 7 can calculate the Latitude and Longitude from an address.  You will have to create a Command Button (call Get Latitude and Longitude), MultiLine Box (Address), two Number Boxes – Latitude and the other Longitude). As you enter the address into the Address Box, click the Command Button and Epi Info will suggest the Latitude and Longitude. If you agree, click Okay, and the Latitude and Longitude boxes will be automatically populated.


1)     Create the Button by clicking and dragging the Command Button Field on the left pane

2)     In the Question or Prompt box type in “Get Latitude and Longitude” and in the Field Name Box type “GetLatLong” – Click Okay. Note you can size the box by grabbing a node, clicking and dragging it to the size you wish.

3)     Use the Multiline field to create the Address Box – Don’t forget to size it properly

4)     Use the Number field to create Latitude and Longitude Boxes. Note that the “Pattern” box should be felt blank.






5)     Now we have to instruct the Command Button to populate the latitude and longitude into the “latitude” and “longitude” boxes

  1. Place you mouse over the Command Button and right click
  2. Select “Field Check Code”
  3. Click the + next to the “[Page 1]:page to expand



  1. Click the + next to the “GetLatLong” CommandButton and then click “click” under that.


You will get the following:


Field GetLatLong


            //add code here





  1. Between Click and End-Click where is says “//add code here: Add the following  GeoCode Address, latitude, Longitude
  2. Check that the code is valid by clicking
  3. Save and Exit





© 2015   Created by phConnect Admin.   Powered by

 |  Report an Issue  |  Terms of Service