+ Reply to Thread
Results 1 to 3 of 3

Find and replace

Hybrid View

Brewel Find and replace 08-27-2014, 01:14 PM
JBeaucaire Re: Find and replace 08-27-2014, 01:45 PM
Brewel Re: Find and replace 08-28-2014, 04:51 AM
  1. #1
    Registered User
    Join Date
    07-05-2013
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    4

    Find and replace

    Hello,

    I am fairly new to VBA to please excuse me if I do not explain my problem clearly.

    I have 2 columns of data in sheet 1.
    On sheet 2 I also have 2 columns of data.
    I would like to find a way of matching the values in the cells of sheet 1 column 1 with the values from same column in sheet 2 i.e column heading "Test#". When a match is found, I need to take the corresponding value from the 2nd column(sheet 2) and paste it into the corresponding 2nd column(Time) in sheet 1.

    I have tried to do this already with findandreplace and the offset function, but I cannot put the replacement value into the right cell.

    Is there a way to do this, or do I need to find another method.

    example layout

    Sheet1                                         Sheet2
    Test #	Time(mins)			Test #	Plate
    1	            5			          1	          A
    1	            6			          2	          B
    1	            7			          3	          C
    1	            8			          4	          D
    2	            10				
    2	            11				
    2	            12				
    2	            13				
    3	            15				
    3	            16				
    3	            17				
    3	            18				
    4	            20				
    4	            21				
    4	            22				
    4	            23
    Last edited by JBeaucaire; 08-27-2014 at 01:43 PM.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Find and replace

    Via formula, on sheet1 B2 put this formula, then copy down:

    =VLOOKUP(A2, Sheet2!$A:$B, 2, 0)
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    07-05-2013
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: Find and replace

    Thank you for your quick reply.

    That function works perfectly for me.

+ 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. [SOLVED] find and replace to not replace characters found as wildcards
    By sabutler4 in forum Excel General
    Replies: 4
    Last Post: 07-03-2013, 06:48 PM
  2. find in excel replace in word: find/replace text in text boxes and headers
    By dean.rogers in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-10-2012, 12:40 PM
  3. Multiple Find and Replace to replace a list of strings
    By WalterP34 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-11-2011, 07:41 PM
  4. Find, and replace but copy cells before replace
    By raehippychick in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-05-2007, 08:16 AM
  5. find and replace - replace data in rows to separated by commas
    By msdker in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-14-2006, 08:10 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