Copying data with same headers from sheet 2 to sheet 1. VBA???

jacobswayne

New Member
Joined
Jan 15, 2020
Messages
12
Office Version
365, 2019
Platform
Windows
Hello everyone. I have had this issue for about a week now and it has been killing me slowly. What I am trying to do is move data from “sheet 2” to “sheet 1”. I only need the values to move over from sheet2 to sheet1 (the headers are the same). For example, on both sheets lets say I have name,address, POC info. Sheet 1 has name and address info, sheet 2 has POC info. I need to move the POC info to sheet 1. When I say poc info its separated by different columns like name, email, phone number,etc. Can someone assist? Does this make sense?? Ive been copying and pasting and its taking me foreverrrrrrrr.

Ive tried vlookup and im not good with vba so neither worked for me. Safe to say im a noob :/


Thank you.
 

Some videos you may like

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.

gallen

Well-known Member
Joined
Jun 27, 2011
Messages
1,996
Does the data follow on? In a cell on sheet 2 you could just have a simple formula like
Rich (BB code):
=Sheet1!A2
Then just copy down..?
 

jacobswayne

New Member
Joined
Jan 15, 2020
Messages
12
Office Version
365, 2019
Platform
Windows
Does the data follow on? In a cell on sheet 2 you could just have a simple formula like
Rich (BB code):
=Sheet1!A2
Then just copy down..?
I need to move data from sheet2 to sheet1. Im not sure what you're talking about my apologies
 

gallen

Well-known Member
Joined
Jun 27, 2011
Messages
1,996
My apologies. Misread.

It's difficult without seeing your data. Do you have the EXACT same list of names in sheet2 as you do in sheet 1?
 

gallen

Well-known Member
Joined
Jun 27, 2011
Messages
1,996
Lets say sheet 1 is like this:

Book1
AB
1NameAddress
2John10 Here
3Jane20 There
Sheet1


And Sheet 2 is like this:

Book1
ABC
1NameEmailPhone
2Johnjohn@a123
3Janejane@b456
Sheet2



Am I right in saying you want the email & phone (POC) details to appear alongside the adjacent columns in Sheet 1, ultimately removing Sheet 2?

If so, is the name data in the same order? If not it will have to be VBA, but still not difficult to achieve. If it's in the same order then even easier, my initial method would work
 

jacobswayne

New Member
Joined
Jan 15, 2020
Messages
12
Office Version
365, 2019
Platform
Windows
when you say list of names do you mean columns? Here are my columns which are the same on both sheets. I would like to move my values over to the other sheet. For example if I have someones email address I would like to move that over to the other sheet that has a cell for their email address. So if I have Bobs name address etc on sheet one I would like to move bobs phone,email,title to sheet one when it resides on sheet 2

ID NumberNameStreet AddressCityStateZip CodeCountryIT NameIT TitleIT EmailIT PhoneIT Name1IT Title1IT Email1IT Phone1Website
 

gallen

Well-known Member
Joined
Jun 27, 2011
Messages
1,996
So the columns are EXACTLY the same on both sheets, but some details are on 1 sheet and some on the other? :unsure: And you want to collaborate all info so it is all on 1 sheet?
 

jacobswayne

New Member
Joined
Jan 15, 2020
Messages
12
Office Version
365, 2019
Platform
Windows
The Column headers are the exact same. However where you "name,address" values may be different or slightly off. Bob dylan may have a leading space on one sheet but not the other.
 

gallen

Well-known Member
Joined
Jun 27, 2011
Messages
1,996
The ID field seems to be the important field. I assume its a numeric?

So in plain English you wish to loop through the ID column on sheet 1, attempt to find that ID on Sheet 2, then for any additional details that aren't showing on sheet 1, import them?
 

jacobswayne

New Member
Joined
Jan 15, 2020
Messages
12
Office Version
365, 2019
Platform
Windows
Yes but I would rather do it by “name” rather than ID because ID number may not match—but yes you are correct. I suppose I can try both
 

Watch MrExcel Video

Forum statistics

Threads
1,102,907
Messages
5,489,654
Members
407,703
Latest member
Chibuzo

This Week's Hot Topics

  • Timer in VBA - Stop, Start, Pause and Reset
    [CODE=vba][/CODE] Option Explicit Dim CmdStop As Boolean Dim Paused As Boolean Dim Start Dim TimerValue As Date Dim pausedTime As Date Sub...
  • how to updates multiple rows in muliselect listbox
    Hello everyone. I need help with below code. code is only chaning 1st row in mulitiselect list box. i know issue with code...
  • Delete Row from Table
    I am trying to delete a row from a table using VBA using a named range to find what I need to delete. My Range is finding the right cell. In the...
  • Assigning to a variable
    I have a for each block where I want to assign the value in column 5 of the found row to the variable Serv. [CODE=vba] For Each ws In...
  • Way to verify information
    Hi All, I don't know what to call this formula, and therefore can't search. I have a spreadsheet with information I want to reference...
  • Active Cell Address – Inactive Sheet
    How to use VBA to get the cell address of the active cell in an inactive worksheet and then place that cell address in a location on the current...
Top