+ Reply to Thread
Results 1 to 3 of 3

Get txt from 'colA' of 'wrkst 1' and find in 'wrkst 2' then replace with txt from 'colB'

  1. #1
    Registered User
    Join Date
    05-08-2014
    MS-Off Ver
    Excel 2003
    Posts
    2

    Get txt from 'colA' of 'wrkst 1' and find in 'wrkst 2' then replace with txt from 'colB'

    Hello Everyone,

    I have found several similar threads, but I am new to VBA and can't seem to figure out the optimal solution to my problem.

    Problem:
    I have two workbooks. Let's call them WORKING and MASTER.

    The MASTER file contains two columns of names. Column A contains the original names (to be searched for in the WORKING file) and Column B contains the respective replacement names (to replace the original names in the WORKING file). I have attached a simplified version of the MASTER file.

    Attachment 317097

    The WORKING file uses the original naming convention. I have attached a simplified version of the WORKING file.

    Attachment 317099

    What I am Looking For:
    I would like to run a macro which searches the WORKING file for all the ORIGINAL names from the MASTER file and replaces the found items with the corresponding NEW names from the MASTER file.

    Assumptions:
    The macro will be called from the WORKING file.
    Both workbooks will be open.
    The Worksheet of the MASTER file will be called 'Lookup Table'

    Any advice would be greatly appreciated. Thank you.

    A.J.

  2. #2
    Registered User
    Join Date
    02-09-2014
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    69

    Re: Get txt from 'colA' of 'wrkst 1' and find in 'wrkst 2' then replace with txt from 'col

    The following should work

    option 1 will match the whole cell value against the name being searched
    option 2 could give problems if for example you have the name fred as a search and the name alfred being replaced


    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    05-08-2014
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Get txt from 'colA' of 'wrkst 1' and find in 'wrkst 2' then replace with txt from 'col

    Amazing stuff. Thank you so much for your help. I really do appreciate it.

+ 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. find first row were colA, colB, colC and colD equal specific values
    By welchs101 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-26-2013, 10:33 AM
  2. SUM(ColB Where ColA=y)
    By brianmo in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-06-2007, 03:10 PM
  3. protect excel wrkst but still be able to use grouping and lists
    By DMS in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 05-17-2006, 04:20 PM
  4. [SOLVED] match colC to ColA, put row from ColB for 'answer'
    By MatthewTap in forum Excel General
    Replies: 4
    Last Post: 10-14-2005, 02:38 PM
  5. want to count in two columns; countif (colA=x AND colB=y)?
    By Heather Murch in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-18-2005, 10:06 AM

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