Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Search and copy macro
I am having two exel files. I need a macro that looks at the number in file1
cell B2, searches that number in file2 column B and copies a number in that row (Mx) to cell C2 in file1. It has to do that for the whole column B in file1. I found some simmilar tutorials, like this one: http://cpearson.com/excel/duplicat.htm but I can't figure out how to do exactlly what I need. Any help would be great! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Search and copy macro
in C2
=if(C2<"",Vlookup($B2,[File2.xls]Sheet1!$A$1:$F$200,3,False),"") drag fill down the column. See Excel help on the vlookup formula. -- Regards, Tom Ogilvy "Frank" wrote in message ... I am having two exel files. I need a macro that looks at the number in file1 cell B2, searches that number in file2 column B and copies a number in that row (Mx) to cell C2 in file1. It has to do that for the whole column B in file1. I found some simmilar tutorials, like this one: http://cpearson.com/excel/duplicat.htm but I can't figure out how to do exactlly what I need. Any help would be great! |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Search and copy macro
Thank you! I didn't know about the vlookup and hlookup commands.
It works now exactly as i wanted it! "Tom Ogilvy" je napisal: in C2 =if(C2<"",Vlookup($B2,[File2.xls]Sheet1!$A$1:$F$200,3,False),"") drag fill down the column. See Excel help on the vlookup formula. -- Regards, Tom Ogilvy "Frank" wrote in message ... I am having two exel files. I need a macro that looks at the number in file1 cell B2, searches that number in file2 column B and copies a number in that row (Mx) to cell C2 in file1. It has to do that for the whole column B in file1. I found some simmilar tutorials, like this one: http://cpearson.com/excel/duplicat.htm but I can't figure out how to do exactlly what I need. Any help would be great! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macro to Search and Copy | Excel Discussion (Misc queries) | |||
Search, Copy, Paste Macro in Excel | Excel Worksheet Functions | |||
Macro to search, compare, copy and delete | Excel Programming | |||
search/copy/paste macro | Excel Programming | |||
Search/copy/paste Macro | Excel Programming |