GLOBAL_MAPPER_SCRIPT

The GLOBAL_MAPPER_SCRIPT must be the first command in the file for scripts prior to v18. . Typically, the entire command line will look like:

GLOBAL_MAPPER_SCRIPT VERSION=1.00

You can use the following parameters with this command:

  • VERSION - specifies the version of the scripting language used. This parameter is required. You should always use VERSION=1.00.
  • ENABLE_PROGRESS - specifies whether or not any progress dialogs should be displayed while this script is processing. This is enabled by default for scripts run in the context of the main map view or when loading workspaces. Scripts run in their own sandbox or from them command line disable progress by default. Use ENABLE_PROGRESS=NO to disable the display of any progress dialogs during the processing of this script.
  • GM_VERSION - specifies the Global Mapper version that a workspace (.gmw) file was saved from. This is in v16.2.2 and later. The format will be like GM_VERSION="16.2.2".
  • TIMESTAMP - specifies the time that the workspace was saved. This will be saved in the ISO-8601 time format, like TIMESTAMP="2015-06-03T13:08:39Z"
  • SHOW_WARNINGS - specifies whether or not warning messages should be displayed when you are done loading the workspace/script into the main map view. Use SHOW_WARNINGS=NO to disable the display of warnings. Any true ERROR messages will always display.
  • LOG_TO_COMMAND_PROMPT - specifies whether or not logged messages should be written to the calling command prompt (if script is passed on the command line). If you add LOG_TO_COMMAND_PROMPT="YES" and you pass the .gms file on the command line, any logged messages will be written to the normal log context as well as the command prompt. Make sure to call global_mapper.exe with 'start /wait' syntax or from a .bat file to ensure that the command line output goes where desired.
  • REQUIRE_WORKSPACE - name of workspace file that is required to be loaded for this script to run. If a name is provided for this parameter and that workspace is not currently loaded into Global Mapper, the script will immediately abort. This can be used if you have different scripts that you only want to use if other workspaces are active and want to prevent accidentally selecting the wrong script.