+ Reply to Thread
Results 1 to 8 of 8

macro to copy part of text from a cell

  1. #1
    Registered User
    Join Date
    12-31-2012
    Location
    Ghent, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    35

    macro to copy part of text from a cell

    Hello, I'm looking for a macro that will give me a copy of the numbers that come after "WIC code" or " Programnumber"

    I've attached an example, to make this more clear.
    I would like to use this macro for the same list (even if there are a lot more rows)...

    Hopefully someone can help me with this one.

    Thanks in advance!
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525

    Re: macro to copy part of text from a cell

    Try
    Please Login or Register  to view this content.
    Last edited by jindon; 01-19-2013 at 04:11 AM.

  3. #3
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: macro to copy part of text from a cell

    hi, formula option
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    12-31-2012
    Location
    Ghent, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    35

    Re: macro to copy part of text from a cell

    Looks very good

    But there are two rows, for which the formula cannot detect the code (in this case program numbers). Any idea why?

  5. #5
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: macro to copy part of text from a cell

    Hello Fugazi_Dent,

    This macro will extract both numbers. It has been added to the atached workbook.
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  6. #6
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525

    Re: macro to copy part of text from a cell

    File attached.

  7. #7
    Registered User
    Join Date
    12-31-2012
    Location
    Ghent, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    35

    Re: macro to copy part of text from a cell

    Thanks a lot to everyone!

    All the options/solution seem to work perfect! This will save me a lot of time.

    Thanks again people.

  8. #8
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: macro to copy part of text from a cell

    formula option
    Attached Files Attached Files

+ Reply to Thread

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