Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 57
Default Working with multiple sheets in a workbook

Hi,

I have 2 seperate sheets in my spredsheet that contains different data each,
but both sheets have a comon factor of inv number and line. I want to be on
sheet 1, lookup the info on sheet 2, if the Inv number and line agree, then
select column c from sheet 2, and insert it into sheet 1.

Example:

Sheet 1:

Culumn A - Invoice No.
Column B - Line No.
Column c - Customer

Sheet 2:
Column A - Inv No.
Column B - Line No.
Column C - Dimension

So if both column A&B match for both sheets, then take column C from sheet
2, and insert it in column D on Sheet 1.

Can this be done.

I tried the VLOOKUP, the IF, the OR, the AND, and nothing seems to work.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Working with multiple sheets in a workbook

Saved from a previous post:

If you want exact matches for just two columns (and return a value from a
third), you could use:

=index(othersheet!$c$1:$c$100,
match(1,(a2=othersheet!$a$1:$a$100)*(b2=othersheet !$b$1:$b$100),0))

(all in one cell)

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

Adjust the range to match--but you can't use the whole column.

This returns the value in othersheet column C when column A and B (of
othersheet) match A2 and B2 of the sheet with the formula.

And you can add more conditions by just adding more stuff to that product
portion of the formula:

=index(othersheet!$d$1:$d$100,
match(1,(a2=othersheet!$a$1:$a$100)
*(b2=othersheet!$b$1:$b$100)
*(c2=othersheet!$c$1:$c$100),0))

Malcolm wrote:

Hi,

I have 2 seperate sheets in my spredsheet that contains different data each,
but both sheets have a comon factor of inv number and line. I want to be on
sheet 1, lookup the info on sheet 2, if the Inv number and line agree, then
select column c from sheet 2, and insert it into sheet 1.

Example:

Sheet 1:

Culumn A - Invoice No.
Column B - Line No.
Column c - Customer

Sheet 2:
Column A - Inv No.
Column B - Line No.
Column C - Dimension

So if both column A&B match for both sheets, then take column C from sheet
2, and insert it in column D on Sheet 1.

Can this be done.

I tried the VLOOKUP, the IF, the OR, the AND, and nothing seems to work.


--

Dave Peterson
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
worksheet to worksheet . . . Wayne Knazek Excel Worksheet Functions 5 September 27th 06 06:57 PM
How do I copy print formatting to multiple sheets in a workbook? BFB@keystone Excel Discussion (Misc queries) 2 March 29th 06 01:34 AM
saving multiple sheets in a workbook Danimal82 Excel Discussion (Misc queries) 2 October 4th 05 05:34 PM
Opening multiple Excel files that contain varied selected sheets MLBrownewell Excel Worksheet Functions 0 September 14th 05 05:48 PM
how do i switch between multiple sheets in the same workbook (key. Catalin Excel Discussion (Misc queries) 3 December 16th 04 06:33 PM


All times are GMT +1. The time now is 10:18 AM.

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

About Us

"It's about Microsoft Excel"