Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Halim,
Instead of displaying the total in the MsgBox, how would I code this to display the total in the first blank row? Thanks. "Halim" wrote: Hi dread, You can do this : Sub Total() Dim R As Range, TTL As Integer For Each R In Range("B1:B50") ' change Range("B1:B50") to your range If R.Value < "" And IsNumeric(R.Value) Then TTL = TTL + R.Value Next R MsgBox TTL End Sub -- Regards, Halim "dread" wrote: I have a macro that copies information from several worksheets into one worksheet. After the information is copied the macro sorts the new worksheet so that blank rows are moved to the end. I want to code the macro to also find the first blank row (after the copied data) and give me totals. How do I do this? Thank you. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How does a function provide a blank cell as a result | Excel Worksheet Functions | |||
how could i detete lots of rows by one commond | Excel Discussion (Misc queries) | |||
Help: Macro Adds Rows, Need to Update Totals with New rows | Excel Programming | |||
Implant macro coding into ASP coding | Excel Programming | |||
KEEP blank rows when coding ranges | Excel Programming |