Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
1SG 1SG is offline
external usenet poster
 
Posts: 1
Default Enter number on a worksheet to copy row from another worksheet

I want to create data on sheet 2 of a spread sheet. Then on sheet 1 I type
in a part number (123456) in B5. The search will go to sheet 2 find that
part number then copies everything in that row on sheet 1. For example the
number 123456 is found on sheet 2 cell A957 then the contents of B957 is
placed in C5 on sheet 1 and C957 is placed in D5 and D957 is placed in E5 and
so on.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Enter number on a worksheet to copy row from another worksheet

Once you have your table of data on Sheet2, define a named range which
encompases it (excluding any headings) - suppose you call this range
"table". Then in Sheet1 you would enter the following formulae in the
cells specified:

C5: =VLOOKUP($B5,table,2,0)
D5: =VLOOKUP($B5,table,3,0)
E5: =VLOOKUP($B5,table,4,0)
F5: =VLOOKUP($B5,table,5,0)

Note that the only difference in the formulae is the third parameter -
this determines which column of the table you would get the data from
if a match is found. This means that you could enter the formula into
C5 and then copy it across as many columns as you need and then just
amend the third parameter. A more general formula would be:

C5: =VLOOKUP($B5,table,COLUMN()-1,0)

and then you could copy this across without having to amend the third
parameter.

Hope this helps.

Pete

On May 21, 11:56 pm, 1SG wrote:
I want to create data on sheet 2 of a spread sheet. Then on sheet 1 I type
in a part number (123456) in B5. The search will go to sheet 2 find that
part number then copies everything in that row on sheet 1. For example the
number 123456 is found on sheet 2 cell A957 then the contents of B957 is
placed in C5 on sheet 1 and C957 is placed in D5 and D957 is placed in E5 and
so on.



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
copy date from worksheet to another worksheet (same File0 wamajkr Excel Discussion (Misc queries) 1 January 15th 07 03:32 PM
How do I copy a check box result from Worksheet A to Worksheet B? Javadan289 Excel Worksheet Functions 5 December 26th 06 07:25 PM
copy part of a worksheet into a worksheet in the same file/keepi. JTB Excel Worksheet Functions 1 September 23rd 06 09:13 AM
Unable to Insert Worksheet/Move and copy worksheet Excel 2003 lukerush Excel Worksheet Functions 2 September 7th 06 05:05 PM
copy data in a cell from worksheet A to worksheet B rajesh Excel Discussion (Misc queries) 1 February 21st 06 07:40 AM


All times are GMT +1. The time now is 08:04 AM.

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"