Ronald, thank you for the find and replace. It works perfect. Makes since now that I see it.


On May 9, 2007, at 4:20 PM, Ronald J Kimball wrote:

On Wed, May 09, 2007 at 04:20:27PM -0400, Mike Freyberger wrote:
I am getting a text file of ads that I am doing several alterations
to within BBEdit. Everything is working fine, however I am stuck on
the last thing. I have each ad header looking like this:
DOE, JOHN
02-MAY-07
23-MAY-07
05/02/2007 05/09/2007 05/16/2007 05/23/2007
02-MAY-07
825462
125814
P.O. BOX 5657

I need the "825814" number to be in a key/value format:
ADNUM: 825814

Each ad has a unique number and each one begins with 82 or 81. (I'm
sure that will change as more files are sent in the future)
Each number is 6 characters long.
Is there a way using perl to get all 6 numbers even though they are
different?

Try this:

Find
(?m)^(8[12]\d{4})$

Replace
ADNUM: \1


Ronald

--
------------------------------------------------------------------
Have a feature request? Not sure the software's working correctly?
If so, please send mail to <[EMAIL PROTECTED]>, not to the list.
List FAQ: <http://www.barebones.com/support/lists/bbedit_talk.shtml>
List archives: <http://www.listsearch.com/BBEditTalk.lasso>
To unsubscribe, send mail to:  <[EMAIL PROTECTED]>



--
------------------------------------------------------------------
Have a feature request? Not sure the software's working correctly?
If so, please send mail to <[EMAIL PROTECTED]>, not to the list.
List FAQ: <http://www.barebones.com/support/lists/bbedit_talk.shtml>
List archives: <http://www.listsearch.com/BBEditTalk.lasso>
To unsubscribe, send mail to:  <[EMAIL PROTECTED]>

Reply via email to