I successfully use this code to find what I want:
member: \n[[:print:]]*\n
Because I want to delete the trailing newline, I would like to replace with most of that (using Posix):
(member: \n[[:print:]]*)\n
This always generates an "Unmatched '(" error.
I appreciate anyone pointing out what I'm doing wrong...
Michael
Can't get tagged expressions to work
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
- Bob Hansen
- Posts: 1516
- Joined: Sun Mar 02, 2003 8:15 pm
- Location: Salem, NH
- Contact:
You are searching for: member: \n[[:print:]]*\n
and Replacing with: (member: \n[[:print:]]*)\n ?
I think you want to Search for: (member: )\n([[:print:]]*)\n
and
Replace with: \1\2
if you are just trying to replace the \n codes.
Note: the Search/Relace I provided are untested.
and Replacing with: (member: \n[[:print:]]*)\n ?
I think you want to Search for: (member: )\n([[:print:]]*)\n
and
Replace with: \1\2
if you are just trying to replace the \n codes.
Note: the Search/Relace I provided are untested.
Hope this was helpful.............good luck,
Bob
Bob
-
- Posts: 3
- Joined: Fri Sep 19, 2003 7:47 pm
That's it!
Actually, I was just trying to join two lines, by deleting the second newline (which picks up a third line, conjoining it to the second line).
Your successful code appears to suggest that \n cannot appear within a tagged expression?
Anyway, it works wonderfully.
I used this for a search:
[/b]
and this for a replace:
[/b]
So, this:
becomes:
TextPad forever...
Michael[/code]
Your successful code appears to suggest that \n cannot appear within a tagged expression?
Anyway, it works wonderfully.
I used this for a search:
Code: Select all
(member: )\n([[:print:]]*)\n
and this for a replace:
Code: Select all
\1\n\2
So, this:
Code: Select all
member:
CN=Feinberg\, Michael,OU=_Users,OU=xxx,OU=xxx,OU=xxx,OU=xxx,OU=xxz
zxxx,DC=xxx,DC=xxx,DC=xxx,DC=xxx
Code: Select all
member:
CN=Feinberg\, Michael,OU=_Users,OU=xxx,OU=xxx,OU=xxx,OU=xxx,OU=xxxxx,DC=xxx,DC=xxx,DC=xxx,DC=xxx
TextPad forever...
Michael[/code]