Change and move a string
-
Hello,
I tried a lot, but nothing worked.
How to move a text in a line?
The lines look about this:[combobox “Text 1”][button “Expand List”]‘/>
[combobox “Text 2”][button “Expand List”]’/>
[combobox “Text 3”][button “Expand List”]'/>and I want to change it like this:
[group “Text 1”].combobox[button “Expand List”]‘/>
[group “Text 2”].combobox[button “Expand List”]’/>
[group “Text 3”].combobox[button “Expand List”]'/>Can anybody help me
Thanks a lot
-
@Knowledge-Base
find what:(\[(combobox) (".+")\])
replace with:\[group \3\]\.\2because
[and]and.do have special meanings in regex, they need to be escaped
in order to treat them literally. -
sorry, find what is to broad, use :
(\[(combobox) (".+?")\]) -
Hello Ekopalypse ,
okay, I’ve tried a completely wrong path.
1447 replaces in less than 1 second - I’m happy :-)Thanks al lot for you help.
-
Hello, @knowledge-base, @ekopalypse,
I was away from the N++ community since more than a month ( see my post below )
https://community.notepad-plus-plus.org/post/47895
So, just for info ! The @ekopalypse solution can even be shortened :
FIND
combobox( ".+?"\])REPLACE
group\1.comboboxBest Regards,
guy038
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login