Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
liseladele
 
Posts: n/a
Default Copying Macro w/ different sheets


I need help with a macro.

I have 5 columns and 75 rows that need a Vlookup function in them.
Each column will be using a different sheet for the Vlookup and each
row will need a differnent column # to retrieve the data. Is there a
macro I can set up to input this data??

Thanks,

Lisel


--
liseladele
------------------------------------------------------------------------
liseladele's Profile: http://www.excelforum.com/member.php...o&userid=32688
View this thread: http://www.excelforum.com/showthread...hreadid=525069

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max
 
Posts: n/a
Default Copying Macro w/ different sheets

Perhaps a formulas approach using INDIRECT to grab
the table_array from the reference sheet would also be feasible ?

Sample construct is available at:
http://www.savefile.com/files/3504820
Vlookup different sheets n different col nums

Assume 3 reference sheets: X, Y, Z
where cols A to G contain lookup data
with col A = lookup values
data from row1 down

In another sheet: Summ,

Ref sheetnames are listed across in B1:C1, eg: X, Y, Z
(vlookup) Col #'s are listed in B2:C2 across, eg: 2, 7, 3
Lookup values are in A3 down

To retrieve the necessary from each reference sheet
for the lookup values in col A,

we could put in B3:
=VLOOKUP($A3,INDIRECT("'"&B$1&"'!A:G"),B$2,0)
and copy B3 across to D3, fill down to populate

Adapt/extend to suit ..
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"liseladele" wrote
in message ...

I need help with a macro.

I have 5 columns and 75 rows that need a Vlookup function in them.
Each column will be using a different sheet for the Vlookup and each
row will need a differnent column # to retrieve the data. Is there a
macro I can set up to input this data??

Thanks,

Lisel


--
liseladele
------------------------------------------------------------------------
liseladele's Profile:

http://www.excelforum.com/member.php...o&userid=32688
View this thread: http://www.excelforum.com/showthread...hreadid=525069



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
creating macro working across multiple sheets Nicole Seibert Excel Worksheet Functions 8 February 28th 06 05:53 PM
apply a macro to all sheets except for a certain sheet minrufeng Excel Discussion (Misc queries) 4 February 22nd 06 02:53 PM
Copying Text to Clip Board Using a Macro robertguy Excel Discussion (Misc queries) 3 February 17th 05 01:11 AM
Sheets Skip Macro NICK Excel Discussion (Misc queries) 2 February 11th 05 07:16 AM
copying text into a macro pagelocator Excel Worksheet Functions 1 November 24th 04 08:52 AM


All times are GMT +1. The time now is 12:51 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"