Generating autocomplete files

The autocomplete function is activated via the Geocoder or Routing widgets, and when enabled, suggests a series of close-matching results to aid the user as input takes place.

To use the autocomplete function, certain files are necessary. The files concerning postal addresses in France are supplied by the company GEOCONCEPT.

It is also possible to generate your own autocomplete files using the data stored in your Geoconcept maps.

For settings, see the next chapter.

Files required

The files needed to generate the autocomplete text options are the following, located in the “<GEOCONCEPT_WEB_HOME>”/ugc/autocompletion/ directory:

  • abbreviations.reference.txt
  • autocomplete.xml
  • build.bat
  • table_cities.txt
  • table_streets.txt

You will need to move these files into the UGC Command line directory: “<GEOCONCEPT_WEB_HOME>”/ugc/cmdline/win64-amd64

[Warning] Warning

The table_cities.txt and table_streets.txt files are the example files for towns in the Loire Atlantique department in France. You should replace them with your own files. To generate these, refer to the documentation: Generate geocoding files

Steps in generating these files

  • Replacing the table_cities.txt and table_streets.txt files with your own files
  • Editing the autocomplete.xml file

    • Editing the general information content
    • Checking the names of cities and streets files
    • Indicate the number of classes (class-number = maximum 8 classes).
[Warning] Warning

The classes represent the order of priority in which the results will be displayed in the autocompletion list. It is possible to add 8 classes. You should first add a column manually entitled WEIGHT in the table_cities.txt file. Next, for each line, you should indicate the desired order.

  • Edit the build.bat file, and check the positioning of the autocomplete.xml file.
  • Execute build.bat by double-clicking on the file. Once the command has been executed, a series of new files is created in the work directory (address and city).
  • Copy the newly created files, as well as autocomplete.xml and abreviations.reference.txt, into the “<GEOCONCEPT_WEB_HOME>”/data/maps/autocomp/Auto_completion/ directory