DEFINE_VAR VALUE issue
Hello!
I am trying to prompt users to select a filename/directory to save a file so I can save it in a variable and use it within my script.
I would like the default location to be the folder of the script itself, however this is not working as expected when I have "FILE_MUST_EXIST=NO".
I am trying to prompt users to select a filename/directory to save a file so I can save it in a variable and use it within my script.
I would like the default location to be the folder of the script itself, however this is not working as expected when I have "FILE_MUST_EXIST=NO".
DEFINE_VAR NAME="GRID_FILE_TO_SAVE" PROMPT="FILE" VALUE="%SCRIPT_FOLDER%XX_NADXX_%FNAME_PARENT_DIR%.gmg" ABORT_ON_CANCEL=YES FILE_MUST_EXIST=NO PROMPT_TEXT="Select a folder and filename to save the grid file"
When I change it to "FILE_MUST_EXIST=YES" it shows the correct folder. I guess the only difference is the "save as" vs the "open file" dialog windows. I don't want users to be confused when they see "open file", when they are trying to save one.
Any ideas why this is not working?
Thanks
Any ideas why this is not working?
Thanks
Tagged:
Answers
-
Actually, when FILE_MUST_EXIST=YES it doesn't let me create a new file, it requires an existing file for sure.
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
