+ Reply to Thread
Results 1 to 5 of 5

Copy Truncated to non Truncated

  1. #1
    Forum Contributor
    Join Date
    03-16-2004
    MS-Off Ver
    2016
    Posts
    175

    Copy Truncated to non Truncated

    Hi

    Names in workbook A, sheet 1 column B are truncated to a max of 11 characters which include spaces, (from dbase3). Those names will match names in workbook B sheet 1 Column A. Names in workbook B are not truncated.

    Need a macro, or formula that will match truncated names in workbook A to full names in workbook B. If a match, copy value in same row from that name, column O, to corresponding name in workbook B sheet 1 Column H.

    In the attached file, the first section represents workbook A with its truncated names. The 2nd sections represents workbook B with the non truncated names. Note they are not in the same order. And the 3rd section shows what I want to happen.

    Thanks
    Attached Files Attached Files

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,703

    Re: Copy Truncated to non Truncated

    Put this formula in P3:

    =IFERROR(MATCH(B3&"*",$A$15:$A$24,0),"")

    then copy down to P12.

    Then you can use this formula in H15:

    =IFERROR(INDEX($O$3:$O$12,MATCH(ROWS($1:1),$P$3:$P$12,0)),"")

    and copy that down as required.

    Hope this helps.

    Pete

  3. #3
    Forum Contributor
    Join Date
    03-16-2004
    MS-Off Ver
    2016
    Posts
    175

    Re: Copy Truncated to non Truncated

    Thanks Pete. But as mentioned, the data is in different workbooks,not on the same sheet. I only put them on the same sheet in the example to try to illustrate what the data looks like. Also there is much more data than what I showed.

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,907

    Re: Copy Truncated to non Truncated

    Try this one.
    Please Login or Register  to view this content.
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

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

    Re: Copy Truncated to non Truncated

    Quote Originally Posted by light View Post
    Hi

    Names in workbook A, sheet 1 column B are truncated to a max of 11 characters which include spaces, (from dbase3). Those names will match names in workbook B sheet 1 Column A. Names in workbook B are not truncated.

    Need a macro, or formula that will match truncated names in workbook A to full names in workbook B. If a match, copy value in same row from that name, column O, to corresponding name in workbook B sheet 1 Column H.

    Thanks
    Try
    You need to change FolderNameHere to correct folder path.
    Formula: copy to clipboard
    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. truncated mean
    By indyffl in forum Excel General
    Replies: 5
    Last Post: 05-23-2011, 03:28 PM
  2. Excel 2007 : cell got truncated
    By pinky8 in forum Excel General
    Replies: 0
    Last Post: 01-19-2011, 07:57 AM
  3. Truncated: copy excel worksheet to powerpoint
    By mapholiday in forum Excel General
    Replies: 1
    Last Post: 05-17-2007, 07:08 PM
  4. [SOLVED] Hyperlinks are truncated
    By [email protected] in forum Excel General
    Replies: 0
    Last Post: 05-12-2006, 01:00 PM
  5. [SOLVED] y label truncated
    By Adam. in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 03-30-2006, 05:30 PM
  6. [SOLVED] GIF File Gets Truncated
    By k2sarah in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 12-02-2005, 01:35 AM
  7. Printing truncated
    By TUNGANA KURMA RAJU in forum Excel General
    Replies: 1
    Last Post: 11-26-2005, 10:00 AM
  8. Replies: 0
    Last Post: 03-03-2005, 11:06 PM

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