Best VBA combo--Loops, find, sum with formatting thrown in

Outofmycomfortzone

New Member
Joined
Jan 28, 2018
Messages
1
This is my first post. Thank you in advance for taking the time to assist me.

I have a formatting question that involves calculations. I have data with several columns, with the focus on 2 columns, namely the 3rd column ("C") and the 8th column ("H").

Column "C" has repeating values and column "H" has their corresponding totals. I need to total the sums of the values that are found in column "C" at the end of the data (number of rows vary from time to time), numerically in their order as they may appear with a slight variation in the format.

The values in "C" can be 11,12,14,21,23. They may not always be inputted but I need to make sure they are checked if periodically inputted and then the summary listed below with their totals. I did not find exactly what I need, just a combination of these steps separately but not sure how to put it together cleanly. I am sorry if this is unclear. Please let me know if you need more info.


[FONT=Helvetica, Arial, Verdana, sans-serif]The formatting part involves other information that needs to summarize the data. It should look like this at the end. Column I7 holds the sum of H1:H6, I8 holds the sum of all values for "14", I9 holds the sum of all values for "21", and H10 holds the sum of the values for "14" & "21" in column I. The values in column "D" in each respective sum row will also need to be part of the coding.[/FONT]


ABCDEFGHI
11870190041030100112.30
11870166501020100355.00
14870122005656350045.31
14870133506006300040.50
21870144506412100360.55
21870140006501100365.00
112020278.66
14280285.81
212802125.55
112801211.36

<tbody style="margin: 0px; padding: 0px; border: 0px; font-family: inherit; vertical-align: baseline;">
</tbody>
****** id="cke_pastebin" style="position: absolute; top: 0px; width: 1px; height: 1px; overflow: hidden; left: -1000px;">
ABCDEFGHI
11870190041030100112.30
11870166501020100355.00
14870122005656350045.31
14870133506006300040.50
21870144506412100360.55
21870140006501100365.00
112020278.66
14280285.81
212802125.55
112801211.36

<tbody style="margin: 0px; padding: 0px; border: 0px; font-family: inherit; vertical-align: baseline;">
</tbody>
</body>
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.

Forum statistics

Threads
1,214,957
Messages
6,122,466
Members
449,086
Latest member
kwindels

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top