NUM(expression) syntax trouble
I'm having some troubles getting my variables defined as numbers, instead of strings. Am I setting this up correctly?
From the reference guide: Note that for the '+' operator, if both operands are numeric, then the operation will be numeric addition; otherwise, the operation will be string concatenation
GLOBAL_MAPPER_SCRIPT VERSION=1.00
From the reference guide: Note that for the '+' operator, if both operands are numeric, then the operation will be numeric addition; otherwise, the operation will be string concatenation
GLOBAL_MAPPER_SCRIPT VERSION=1.00
DEFINE_VAR NAME=VAR1 VALUE=10
DEFINE_VAR NAME=VAR2 FORMULA=NUM(VAR1)
DEFINE_VAR NAME=VAR3 FORMULA=VAR2+1
This is the output from script above
Defined variable VAR1 to value 10
Defined variable VAR2 to value 10
Defined variable VAR3 to value 101
Answers
-
I'm running v18.1 and getting 11 for VAR3. What version are you running, and if not the latest, suggest updating yours.
-
I am running v16, and I'm not sure my license supports upgrades...
-
I don't have an installation of v16 any more. Please send your first posting to Blue Marble Geographics Support (geohelp@bluemarblegeo.com). It will help if you include the build number along with the version as noted at the top of your Global Mapper window. This will ensure that the support team sees your problem. They may have a useful response for your v16.
Categories
- 13K All Categories
- 5.8K Features Discussion
- 350 Downloading Imagery
- 1.3K Elevation Data
- 385 Georeferencing Imagery Discussion
- 652 GM Script Language
- 56 User Scripts
- 115 GPS Features
- 421 Projection Questions
- 835 Raster Data
- 1.4K Vector Data
- 6.7K Support
- 181 Announcement and News
- 939 Bug Report
- 562 SDK
- 1.2K Suggestion Box
- 3.7K Technical Support
- 579 Other Discussion
- 132 GIS Data Sources
- 27 Global Mapper Showcase
- 244 How I use Global Mapper
- 110 Global Mapper Forum Website

