Results 1 to 4 of 4

Parsing out text

Threaded View

  1. #1
    Registered User
    Join Date
    08-31-2005
    Posts
    5

    Parsing out text

    Hi,

    I have a column of alpha-numeric strings with an address in the middle as follows:

    John Doe 06 CH 1837 123 Any St, Any Town, IL 60612 Pierce & Associates

    The red text (the address) is what I want to cut from this string and move to an adjacent column.

    The string starts with a name of any length, but I know that every string has the blue text that always starts with CH and then is followed by a space and four integers as shown above. The numbers change but the CH is constant.

    So I know that I need to search each line for CH, move to the right 5 spaces past that (to the beginning of the address), and cut everything up until the end of the next 5 integers (the zip code), then move it to the next column. And then some sort of loop applied.

    I know what I need done I just don't know how to write the macro. Can anyone please help. Many thanks in advance.

    EDIT: By the way the text in the workbook is not colored red or blue, only here for purpose of illustration.

    Ryan
    Last edited by VBA Noob; 02-10-2007 at 07:53 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1