Reputation: 21
I know it sounds weird but I have a list of names (excluding surnames) and I need them all uppercase within square brackets. For example from Michael
to [MICHAEL]
for all words in all lines in the entire document.
What code can I use to replace all in Regular expression Search Mode?
Upvotes: 0
Views: 184
Reputation: 1840
Search for whole words:
([A-Za-z0-9-]+)
Replace them with this to add brackets and convert all letters to upper case:
[\U\1]
Upvotes: 2