Solved

textpad regex replace between 2 quotes

Posted on 2014-12-04
9
512 Views
Last Modified: 2014-12-04
I am using textpad and need to delete everything within quotes like below.

this is the current code
<OrderDocumentCode Code="00000000" />

this is what i need it to look like.
<OrderDocumentCode Code="" />

There are other quotes in the document so it would need to include the tag OrderDocumentCode

Thanks in advance
0
Comment
Question by:jacobJL
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
9 Comments
 
LVL 25

Accepted Solution

by:
NVIT earned 500 total points
ID: 40481520
Find what: (<OrderDocumentCode Code=\")([0-9].+)(\" />)
Replace with: \1\3
0
 

Author Comment

by:jacobJL
ID: 40481614
Thanks for the response. I am getting cannot find regular expression. Please see screen shot
error
0
 
LVL 25

Expert Comment

by:NVIT
ID: 40481624
Move your cursor to the top of the file. Then try again
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:jacobJL
ID: 40481640
still didn't work.
0
 

Author Comment

by:jacobJL
ID: 40481646
here is a sample file if that helps
0
 
LVL 25

Expert Comment

by:NVIT
ID: 40481657
Configure, Preferences, Editor. Check "Use POSIX..."
0
 
LVL 35

Expert Comment

by:Dan Craciun
ID: 40481734
Why not simply:
Find what: <OrderDocumentCode Code="\d*" />
Replace with: <OrderDocumentCode Code="" />

You're basically deleting something, so the groups are not really necessary.

HTH,
Dan
0
 

Author Closing Comment

by:jacobJL
ID: 40481765
This solution combined with Configure, Preferences, Editor. Check "Use POSIX..." worked. Thank you so much.
0
 
LVL 25

Expert Comment

by:NVIT
ID: 40481778
@Dan: Thanks for that. I tend to forget the simple things. *sigh*
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whatever be the reason, if you are working on web development side,  you will need day-today validation codes like email validation, date validation , IP address validation, phone validation on any of the edit page or say at the time of registration…
How to install Selenium IDE and loops for quick automated testing. Get Selenium IDE from http://seleniumhq.org Go to that link and select download selenium in the right hand column That will then direct you to their download page. From that p…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question