Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I was searching previous posts before posting my question and didn't find any
that addressed this specific situation. I have a workbook with 10 sheets. All 10 sheets have code that totals up column D and puts the sum at the bottom of the sheet. This sum is never located in the same row as the report lengths vary each day. Is there a wayt to create a summary sheet and list the totals from each sheet on the summary page with VBA code rather thatn copy and paste them all on to the summary page? For example Sheet titled "cards" has Sum in Column D, row 56 Sheet titled "checks" has sum in Column D row 66 Sheet Titled "cash" has sum in column D row 156. The only common thread is the total on each sheet is the last text in Column D on that sheet. Also the row number varies each day so my question is how would I code to copy the last cell in Column D on the sheet titled Cards with a sum total to sheet titled Summary into Cell B4, the same for sheet Checks copy to cell B5 in Summary sheet and Cash to cell B6. Is this even possible. Thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This will populate the "Summary" sheet with each sheets name in Column A and
Column D total in column B. Sub totals() Dim c As Integer Dim sht As Worksheet c = 4 For Each sht In ThisWorkbook.Sheets If sht.Name < "Summary" Then With Sheets("Summary") .Cells(c, 1).Value = sht.Name .Cells(c, 2).Value = _ sht.Cells(Rows.Count, 4).End(xlUp).Value End With c = c + 1 End If Next sht End Sub Hope this helps Rowan "SITCFanTN" wrote: I was searching previous posts before posting my question and didn't find any that addressed this specific situation. I have a workbook with 10 sheets. All 10 sheets have code that totals up column D and puts the sum at the bottom of the sheet. This sum is never located in the same row as the report lengths vary each day. Is there a wayt to create a summary sheet and list the totals from each sheet on the summary page with VBA code rather thatn copy and paste them all on to the summary page? For example Sheet titled "cards" has Sum in Column D, row 56 Sheet titled "checks" has sum in Column D row 66 Sheet Titled "cash" has sum in column D row 156. The only common thread is the total on each sheet is the last text in Column D on that sheet. Also the row number varies each day so my question is how would I code to copy the last cell in Column D on the sheet titled Cards with a sum total to sheet titled Summary into Cell B4, the same for sheet Checks copy to cell B5 in Summary sheet and Cash to cell B6. Is this even possible. Thanks |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Good Morning Rowan,
I don't understand this code, where does it stipulate to pull the sum total numbers from the last cell in each sheet in column D. I just want to understand the code I use. Also can I just stipulate copying the sum totals from some of my sheets, not all of them (call each sheet specifically). Thanks a bunch for your help. Joyce "Rowan Drummond" wrote: This will populate the "Summary" sheet with each sheets name in Column A and Column D total in column B. Sub totals() Dim c As Integer Dim sht As Worksheet c = 4 For Each sht In ThisWorkbook.Sheets If sht.Name < "Summary" Then With Sheets("Summary") .Cells(c, 1).Value = sht.Name .Cells(c, 2).Value = _ sht.Cells(Rows.Count, 4).End(xlUp).Value End With c = c + 1 End If Next sht End Sub Hope this helps Rowan "SITCFanTN" wrote: I was searching previous posts before posting my question and didn't find any that addressed this specific situation. I have a workbook with 10 sheets. All 10 sheets have code that totals up column D and puts the sum at the bottom of the sheet. This sum is never located in the same row as the report lengths vary each day. Is there a wayt to create a summary sheet and list the totals from each sheet on the summary page with VBA code rather thatn copy and paste them all on to the summary page? For example Sheet titled "cards" has Sum in Column D, row 56 Sheet titled "checks" has sum in Column D row 66 Sheet Titled "cash" has sum in column D row 156. The only common thread is the total on each sheet is the last text in Column D on that sheet. Also the row number varies each day so my question is how would I code to copy the last cell in Column D on the sheet titled Cards with a sum total to sheet titled Summary into Cell B4, the same for sheet Checks copy to cell B5 in Summary sheet and Cash to cell B6. Is this even possible. Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Summary page | Excel Discussion (Misc queries) | |||
Summary Page | Excel Programming | |||
Summary page | Excel Programming | |||
Summary on one page | Excel Programming | |||
How do I create a summary page? | Excel Programming |