+ Reply to Thread
Results 1 to 3 of 3

Thread: Mass Find and Replace Macro

  1. #1
    Registered User
    Join Date
    08-08-2010
    Location
    Adelaide, Australia
    MS-Off Ver
    Excel 2007
    Posts
    2

    Post Mass Find and Replace Macro

    Hi

    I have a workbook with three sheets (see attached). The "Import Data" sheet will have data imported from text files (I have only included one in the work book but there could be several hundred). Columns C has numbers which can be found on the "Item ID" sheet, with the cooresponding name in column B. Similarly with Column K and the "Station ID" sheet.

    What I am trying to do is make a macro that will Find and Replace all of the numbers in columns C and K in the "Import Data" sheet with their cooresponding values from the "Item ID" and "Station ID" sheets.

    Any help/advise would be greatly appreciated.

    Thanks in advance.
    Attached Files Attached Files
    Last edited by Singularity7250; 08-09-2010 at 08:14 AM.

  2. #2
    Forum Moderator Richard Buttrey's Avatar
    Join Date
    02-15-2008
    Location
    Grappenhall, UK
    MS-Off Ver
    Excel for Windows & Mac - all versions.
    Posts
    6,566

    Re: Mass Find and Replace Macro

    Hi,

    No need for a macro. Why not just use a couple of VLOOKUP() functions in two helper columns. e.g.

    O2: =VLOOKUP(C2,'Item ID'!$A$1:$B$25577,2,FALSE)
    P2: =VLOOKUP(K2,'Station ID'!$A$1:$B$5329,2,FALSE)
    copy O2:P2 down your list then finally select the values in column O, copy them and paste them back to column C as Values. Ditto with columns P & K

    HTH
    Richard Buttrey

    If this was useful then please rate it appropriately.

    Click the small star icon at the bottom left of my post.

  3. #3
    Registered User
    Join Date
    08-08-2010
    Location
    Adelaide, Australia
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Mass Find and Replace Macro

    Hi Richard,

    It worked a treat!

    Thanks alot for your help!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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.2.0