Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Adding up cell values only with identical info in other cells

What I would like to do is add up hours shown within specific columns or
ranges on multiple timesheets. But here's the tricky part, to add up only
those cells that have all the same number (i.e. job no.)in a different column
within that same row.
Example: One worksheet
Job Hours
601 8
602 16
601 4
704 11
408 6
602 7

Now to add up hours for each job no. on another totals worksheet:
Job Total Hours
408 6
601 12
602 23
704 11

While at the same time having the cells on the total worksheet linked to the
source, so if I change or clear the hours cell or the job no. cell in the
source range, the totals reflect it.
Is there a way to do this? Please help.

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Adding up cell values only with identical info in other cells

A Pivot Table will do exactly what you want:

Sum of Hours by Job number.

see:

http://peltiertech.com/Excel/Pivots/pivotstart.htm
--
Gary''s Student - gsnu200768


"rarch1" wrote:

What I would like to do is add up hours shown within specific columns or
ranges on multiple timesheets. But here's the tricky part, to add up only
those cells that have all the same number (i.e. job no.)in a different column
within that same row.
Example: One worksheet
Job Hours
601 8
602 16
601 4
704 11
408 6
602 7

Now to add up hours for each job no. on another totals worksheet:
Job Total Hours
408 6
601 12
602 23
704 11

While at the same time having the cells on the total worksheet linked to the
source, so if I change or clear the hours cell or the job no. cell in the
source range, the totals reflect it.
Is there a way to do this? Please help.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,345
Default Adding up cell values only with identical info in other cells

But a pivot table will not update the way the the OP want it to

--
Regards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Gary''s Student" wrote in message
...
A Pivot Table will do exactly what you want:

Sum of Hours by Job number.

see:

http://peltiertech.com/Excel/Pivots/pivotstart.htm
--
Gary''s Student - gsnu200768


"rarch1" wrote:

What I would like to do is add up hours shown within specific columns or
ranges on multiple timesheets. But here's the tricky part, to add up only
those cells that have all the same number (i.e. job no.)in a different
column
within that same row.
Example: One worksheet
Job Hours
601 8
602 16
601 4
704 11
408 6
602 7

Now to add up hours for each job no. on another totals worksheet:
Job Total Hours
408 6
601 12
602 23
704 11

While at the same time having the cells on the total worksheet linked to
the
source, so if I change or clear the hours cell or the job no. cell in the
source range, the totals reflect it.
Is there a way to do this? Please help.




  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,480
Default Adding up cell values only with identical info in other cells

Hi Sandy

Whilst I agree that PT's do not update automatically, it is only a single
line of code set in a worksheet activate event to make it do so

Private Sub Worksheet_Activate()
ActiveSheet.PivotTables("PivotTable1").PivotCache. Refresh
End Sub

The name of the PT would need to be set to the name of the PT on the OP's
worksheet. This can be found by right clicking on the PTTable OptionsName

--
Regards
Roger Govier

"Sandy Mann" wrote in message
...
But a pivot table will not update the way the the OP want it to

--
Regards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Gary''s Student" wrote in
message ...
A Pivot Table will do exactly what you want:

Sum of Hours by Job number.

see:

http://peltiertech.com/Excel/Pivots/pivotstart.htm
--
Gary''s Student - gsnu200768


"rarch1" wrote:

What I would like to do is add up hours shown within specific columns or
ranges on multiple timesheets. But here's the tricky part, to add up
only
those cells that have all the same number (i.e. job no.)in a different
column
within that same row.
Example: One worksheet
Job Hours
601 8
602 16
601 4
704 11
408 6
602 7

Now to add up hours for each job no. on another totals worksheet:
Job Total Hours
408 6
601 12
602 23
704 11

While at the same time having the cells on the total worksheet linked to
the
source, so if I change or clear the hours cell or the job no. cell in
the
source range, the totals reflect it.
Is there a way to do this? Please help.




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,345
Default Adding up cell values only with identical info in other cells

Not only that but it looks like the OP has decided to go down the PT road as
well.

--
Regards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Roger Govier" <roger@technology4unospamdotcodotuk wrote in message
...
Hi Sandy

Whilst I agree that PT's do not update automatically, it is only a single
line of code set in a worksheet activate event to make it do so

Private Sub Worksheet_Activate()
ActiveSheet.PivotTables("PivotTable1").PivotCache. Refresh
End Sub

The name of the PT would need to be set to the name of the PT on the OP's
worksheet. This can be found by right clicking on the PTTable
OptionsName

--
Regards
Roger Govier

"Sandy Mann" wrote in message
...
But a pivot table will not update the way the the OP want it to

--
Regards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Gary''s Student" wrote in
message ...
A Pivot Table will do exactly what you want:

Sum of Hours by Job number.

see:

http://peltiertech.com/Excel/Pivots/pivotstart.htm
--
Gary''s Student - gsnu200768


"rarch1" wrote:

What I would like to do is add up hours shown within specific columns
or
ranges on multiple timesheets. But here's the tricky part, to add up
only
those cells that have all the same number (i.e. job no.)in a different
column
within that same row.
Example: One worksheet
Job Hours
601 8
602 16
601 4
704 11
408 6
602 7

Now to add up hours for each job no. on another totals worksheet:
Job Total Hours
408 6
601 12
602 23
704 11

While at the same time having the cells on the total worksheet linked
to the
source, so if I change or clear the hours cell or the job no. cell in
the
source range, the totals reflect it.
Is there a way to do this? Please help.









  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,180
Default Adding up cell values only with identical info in other cells

Here are several methods that work across
multiple worksheets. Includes Pivot Table.
Excel 2003
http://www.freefilehosting.net/download/3bm61
  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default Adding up cell values only with identical info in other cells

Thanks for the help. It looks like I can do this really well with a pivot
table, but I'll have to work with it a bit and set up the source ranges a
little differently. But I also got the SUMIF formula to work also using
SUMIFS to add multiple criteria similar to fields in the pivot table and then
stringing the function together for multiple sheet references. Example:
=SUMIFS(Sheet1!B2:B7,Sheet1!A2:A7,"408")+SUMIFS(Sh eet2!B2:B7,Sheet2!A2:A7,"408")+...and so on... for the hours for '408'.
=SUMIFS(Sheet1!B2:B7,Sheet1!A2:A7,"601")+SUMIFS(Sh eet2!B2:B7,Sheet2!A2:A7,"601")+...and so on... for the hours for '601'.
This SUMIFS function method works for what I need right now, but it takes
lots of time inserting repetitive formulas for each field. I think the pivot
table will be more versatile - but I'll need to get more acquainted with all
the options first.
Thanks to everyone for your help on this!

rarch1

"Herbert Seidenberg" wrote:

Here are several methods that work across
multiple worksheets. Includes Pivot Table.
Excel 2003
http://www.freefilehosting.net/download/3bm61

  #10   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,836
Default Adding up cell values only with identical info in other cells

Dang! Just take a look at Herbert's multiple methods and you can begin to
appreciate how powerful Pivot Tables really are!



--
RyGuy


"rarch1" wrote:

Thanks for the help. It looks like I can do this really well with a pivot
table, but I'll have to work with it a bit and set up the source ranges a
little differently. But I also got the SUMIF formula to work also using
SUMIFS to add multiple criteria similar to fields in the pivot table and then
stringing the function together for multiple sheet references. Example:
=SUMIFS(Sheet1!B2:B7,Sheet1!A2:A7,"408")+SUMIFS(Sh eet2!B2:B7,Sheet2!A2:A7,"408")+...and so on... for the hours for '408'.
=SUMIFS(Sheet1!B2:B7,Sheet1!A2:A7,"601")+SUMIFS(Sh eet2!B2:B7,Sheet2!A2:A7,"601")+...and so on... for the hours for '601'.
This SUMIFS function method works for what I need right now, but it takes
lots of time inserting repetitive formulas for each field. I think the pivot
table will be more versatile - but I'll need to get more acquainted with all
the options first.
Thanks to everyone for your help on this!

rarch1

"Herbert Seidenberg" wrote:

Here are several methods that work across
multiple worksheets. Includes Pivot Table.
Excel 2003
http://www.freefilehosting.net/download/3bm61



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
adding values of cells AJ Patel New Users to Excel 2 January 4th 08 10:27 PM
Adding Values to Cells Dana Excel Discussion (Misc queries) 18 December 20th 07 05:15 AM
Looking Up Datas when Key Values are Identical Frank Excel Worksheet Functions 3 November 2nd 06 03:06 AM
Lookup of identical values? TobbeGardner Excel Worksheet Functions 3 July 5th 06 10:50 PM
Link info in one cell to info in several cells in another column (like a database) hansdiddy Excel Discussion (Misc queries) 1 February 22nd 06 02:27 AM


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