Possible Duplicate:
Copy column from one Excel sheet to another Excel sheet
I have 5 sheets in my Excel file. Out of these 5, one is the master sheet which has all the data I want to copy to the other 4 sheets.
All the sheets have one common column, ID. The master has more than 10000 IDs.
What I want to do is:
If ID in sheet1 = 24356 = ID in master sheet then copy x, y, z columns from master sheet to sheet1. This is same for all other sheets.
Also, since the master sheet is from another source than the rest of the sheets, its formatting is different. Is there a way to remove all formatting in sheets before running copy/paste?
Can anyone please tell me the VBA code to do this.
This is what my Master sheet looks like:

I want the other sheet (e.g. sheet1) in this case to look like:

Also, while searching the master sheet, is it possible for the code to look through the last column of the sheet?
Nupur
Here is the non-VBA way.
Assume your master data is on a sheet called
Masterand the data is in rangeA1:H9. Now assume I haveSheet1with a list of IDs in rangeA2:A5.Then in
Sheet1in cellB2I have the following to retrieveNameforID=475:To get
TypeforID=475I use:All I am doing is setting up a reference to the data table on
Master(note absolute ref with $ signs), using ID as the lookup value, and then changing the column value (3rd input in VLOOKUP) to retreive the relevant value.Once you have set this up for the first row you can then just copy down and get the right data populated.
Does this solve the issue?