#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 788
Default vlookup. HELP

I am trying to use vlookup to take a name from colum a on one work book and
look for numbers in another work book. I can do that fine. The problem is
that in the second work book there are many numbers for the same person and I
need these to be added together and a total of these numbers reported in
colum B in the first work book. Can anyone help
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default vlookup. HELP

Try SUMIF ..

Assuming source numbers to be added up are in Book2.xls in Sheet1's col B,
where the names are in col A

With Book2.xls simultaneously open,

In Book1.xls, in say, Sheet1,
assume the names are running in A1 down

Put in B1:
=SUMIF([Book2]Sheet1!$A:$A,A1,[Book2]Sheet1!$B:$B)
Copy B1 down
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Chris" wrote:
I am trying to use vlookup to take a name from colum a on one work book and
look for numbers in another work book. I can do that fine. The problem is
that in the second work book there are many numbers for the same person and I
need these to be added together and a total of these numbers reported in
colum B in the first work book. Can anyone help

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 94
Default vlookup. HELP

On 31 Jan., 14:25, Chris wrote:
I am trying to use vlookup to take a name from colum a on one work book and
look for numbers in another work book. I can do that fine. The problem is
that in the second work book there are many numbers for the same person and I
need these to be added together and a total of these numbers reported in
colum B in the first work book. Can anyone help


Hi Chris,

Maybe you can use
Sumif()

Regards,
Bondi

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 195
Default vlookup. HELP

Hi Chris,

If I have understood your problem correctly

On the second work book write the formula at cell B2

=SUMIF(sheet1!A1:B10,B1,B1:B10)

B1 will have the name of the person.
This will sum-up the numbers for the person you are looking at the
first work book

I hope this helps you.


Thanks,

Shail
On Jan 31, 6:25 pm, Chris wrote:
I am trying to use vlookup to take a name from colum a on one work book and
look for numbers in another work book. I can do that fine. The problem is
that in the second work book there are many numbers for the same person and I
need these to be added together and a total of these numbers reported in
colum B in the first work book. Can anyone help



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 35,218
Default vlookup. HELP

=sumif() sounds like a very good solution if the "sending" workbook is open.

But =sumif() won't work if you close that workbook.

You could use =sumproduct() though.

If you open both books, you can build the formula by typing and
pointing/selecting.

It should look something like:
=SUMPRODUCT(--(A1=[book3.xls]Sheet1!$A$1:$A$17),[book3.xls]Sheet1!$B$1:$B$17)

with the workbook open.

Adjust the ranges to match--but you can't use whole columns (except in xl2007).

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

Chris wrote:

I am trying to use vlookup to take a name from colum a on one work book and
look for numbers in another work book. I can do that fine. The problem is
that in the second work book there are many numbers for the same person and I
need these to be added together and a total of these numbers reported in
colum B in the first work book. Can anyone help


--

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
VLookup a Vlookup adamb2000 Excel Worksheet Functions 4 June 28th 06 10:54 PM
VLOOKUP Problem Ian Excel Discussion (Misc queries) 3 April 6th 06 06:47 PM
VLOOKUP Limitations chris_manning Excel Worksheet Functions 2 August 9th 05 06:23 PM
vlookup data hidden within worksheet Excel Worksheet Functions 0 January 26th 05 12:09 PM
Vlookup info being used without vlookup table attached? Excel Worksheet Functions 0 January 25th 05 10:43 AM


All times are GMT +1. The time now is 01:00 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"