LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Find percentage of sums

Now that I have this code, there is one last step which I don't know how to
write. If I record, it will be based on specific cells, which I never know
where the end will be. WIth that said, I used the following code provided
earlier that works great, but I need to now take the result of these two
numbers to figure a percent. Specifically =sum(b?-c?)/c?


Dim LastRow As Long
LastRow = Cells(Cells.Rows.Count, 1).End(xlUp).Row
Cells(LastRow + 1, 2).Formula = "=sum(b1:b" & LastRow & ")"

LastRow = Cells(Cells.Rows.Count, 1).End(xlUp).Row
Cells(LastRow + 1, 3).Formula = "=sum(c1:c" & LastRow & ")"


How can I write take the last number in columnl b minus last row in column
c divided by last row in column c? The result will be listed in the last
row of column D.

Thanks much!


 
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
find percentage israel New Users to Excel 4 April 1st 23 09:45 PM
Find percentage ??? Bernard Liengme Excel Worksheet Functions 1 December 12th 05 04:40 AM
Find percentage ??? [email protected] Excel Worksheet Functions 0 December 10th 05 07:50 PM
How do I find a percentage? PBarton Excel Discussion (Misc queries) 2 November 27th 05 10:40 PM
Find blank cells and calculate sums AlisonB Excel Programming 5 December 2nd 03 05:15 PM


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

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"