Exporting attributes in shapefile as integer, double or float instead of string
Is it possible to export shapefiles where the attributes are numbers instead of strings? I have contours derived from LiDAR data I want to manipulate in other programs and scripts, but because the Elevation attribute (for example) is a string, I have to preform a work around instead of a simple function. Perhaps I missed a button?
Tagged:
Answers
-
Hello,
There are a couple of things you can do. First, when you create contours, be sure to remove the check mark from the option to append unit labels to elevation values. Then, when exporting the shapefile, look at the Attribute Setup tab on the Shapefile Export Options window. The type for the ELEVATION column should now be a numeric type (integer or float).
Cheers,
Bob -
Thank you Bob! I did miss a button.
-
You're way beyond me. Sorry I don't know what you mean. Can I upload the files for you to look at?
-
I have the same problem, Global Mapper seem to automatically calculate the field type based on the content (i.e. if it reconize an integer then it creates a numeric field).
How can I set up my fields types in a shapefile while exporting it with a script ? I know this could be done while manually exporting a shapefile, but what about using a script?
-
Hello,
We have an open feature request to add this functionality, but it is not currently scheduled for implementation. I have added your information to the ticket (GM-5194). Thank you.
Cheers,
Bob
Categories
- 12.8K All Categories
- 5.7K Features Discussion
- 346 Downloading Imagery
- 1.3K Elevation Data
- 385 Georeferencing Imagery Discussion
- 639 GM Script Language
- 54 User Scripts
- 115 GPS Features
- 417 Projection Questions
- 829 Raster Data
- 1.3K Vector Data
- 6.6K Support
- 179 Announcement and News
- 922 Bug Report
- 559 SDK
- 1.2K Suggestion Box
- 3.7K Technical Support
- 573 Other Discussion
- 131 GIS Data Sources
- 27 Global Mapper Showcase
- 241 How I use Global Mapper
- 108 Global Mapper Forum Website