Search and Replace
Roger Edrinn
Global Mapper UserTrusted User
While their are extensive search parameters in the search dialog, replace seems to be a manual operations. Correct?
I'd like to be able to search for a text string and replace it with another text string. Much like Search and Replace in a text editor.
This would be a nice compliment to nested searches in v10.
Thanks
I'd like to be able to search for a text string and replace it with another text string. Much like Search and Replace in a text editor.
This would be a nice compliment to nested searches in v10.
Thanks
Comments
-
-
What is the status of Search & Replace?
Thanks -
Roger,
I haven't looked at that yet. Can you explain exactly what you would like this to do? Perhaps a search for an entire string or would just partial matches work? I'm thinking of making this a separate menu item under the Search menu. I may be able to look at this in the next few days before I head out for vacation.
Thanks,
Mike
Global Mapper Support
support@globalmapper.com -
Looking at the attachment, you'll see that all the Feature Names are in caps. But they display, in a Garmin GPS, with only the first letter in a word capitalized. So in order to "trick" capitalization, you need to insert spaces.
By example: HUGO SWA will display as Hugo Swa. However HUGO S W A will display as Hugo S W A.
To accomplish this with the current tools, each unique name must be manually selected and edited. I'd like a global S&R so that I could find all cases of SWA and replace only the SWA portion with S W A and not affect the feature name itself.
Given your past demonstrations of super human coding, should take no more than 2 hours.
Thanks
While you're at it, I'd like Pre-pend A-pend abilities too. Such that I could take any text string and either pre-pend or a-pend a text sting to an existing text string. I'm pretty sure this is allowed in the layer manager > options, but not in search. -
Roger,
I think I can make that happen. I'll try and get a simple Search and Replace added in the next couple of days. You should be able to use the Search-and-Replace to do a pre-pend and append too just by including the original search string with the pre-pend or append text before or after it in the replace string.
Thanks,
Mike
Global Mapper Support
support@globalmapper.com -
global_mapper wrote: »You should be able to use the Search-and-Replace to do a pre-pend and append too just by including the original search string with the pre-pend or append text before or after it in the replace string.
Using my example above, I'd like to pre-pend a string to Hugo and all other feature names. My wee brain says S&R will not do this. I'll await your superior gray matter.
Thanks -
Ah yes, that would be a bit harder. It could be done if the search and replace strings supported wildcards though. For example you could search on '*' and replace with 'Prefix *' to add 'Prefix ' to the front of all names. This will be a bit harder for me but should still be possible.
Thanks,
Mike
Global Mapper Support
support@globalmapper.com -
Roger,
I have completed adding a 'Search and Replace' option to the Search menu. In addition to normal search-and-replace, if you use a single '*' character in the replace string you can use that to keep the original text and prepend and/or append data, like using 'Prefix*Suffix'. I have placed a new build at http://www.globalmapper.com/global_mapper10.zip with the change for you to try. Simply download that file and extract the contents into your existing v10.xx installation folder to give it a try.
Let me know if I can be of further assistance.
Thanks,
Mike
Global Mapper Support
support@globalmapper.com -
Finally got a chance to try this, super slick!!! That which would have taken hours is done in the blink of an eye.
I do have an improvement suggestion:
Instead of having three cascading dialogs, I suggest:
One dialog with the Class Search and Replace fields in a stack.
Two don't close the dialog.
Three don't clear the fields.
I found myself doing repetitive S&R with very similar strings.
All and all a wonderful tool.
Many thanks. -
Roger,
Thanks for the suggestion, I agree it is better as one dialog. I have placed a new build at http://www.globalmapper.com/global_mapper10.zip with the change for you to try. Simply download that file and extract the contents into your existing v10.xx installation folder to give it a try.
Let me know if I can be of further assistance.
Thanks,
Mike
Global Mapper Support
support@globalmapper.com -
global_mapper wrote: »I may be able to look at this in the next few days before I head out for vacation.
IIRC, vacation for you consist of fast flowing water with you hanging on for dear-life on an fragile inflatable raft. Sounds like the prefect brain flush alternative to coding. -
Yeah I've had a few short vacations since then. I even went rafting on one last week, but just class II-III in North Carolina as it was with family. The real rafting season is just about finally here so it is time to hit the big stuff!
Categories
- 12.7K All Categories
- 5.6K Features Discussion
- 342 Downloading Imagery
- 1.3K Elevation Data
- 380 Georeferencing Imagery Discussion
- 628 GM Script Language
- 53 User Scripts
- 113 GPS Features
- 414 Projection Questions
- 819 Raster Data
- 1.3K Vector Data
- 6.6K Support
- 177 Announcement and News
- 908 Bug Report
- 558 SDK
- 1.2K Suggestion Box
- 3.7K Technical Support
- 562 Other Discussion
- 129 GIS Data Sources
- 27 Global Mapper Showcase
- 233 How I use Global Mapper
- 107 Global Mapper Forum Website