Hopefully, I just need one last fav, is there a possibility, if I re-run the macro. It deletes the entire process and repeats this macro again. and add a Grand total at the bottom of the last page.
Running the macro again after it has been run will not 'delete the process'. However, if you want the macro changed so that, starting with the original data, it does what it already does plus also adds a Grand Total row then try this version.
<font face=Courier New><br><SPAN style="color:#00007F">Sub</SPAN> STot()<br> <SPAN style="color:#00007F">Dim</SPAN> a, st, strw, t, gt<br> <SPAN style="color:#00007F">Dim</SPAN> i <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN>, lr <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN>, c <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN><br> <br> st = Array("Sub-Total", 1, "@ Dia 12", 12, "@ Dia 16", 16, _<br> "@ Dia 20", 20, "@ Dia 24", 24, "@ Dia 28", 28, _<br> "@ Dia 32", 32, "@ Dia 36", 36, "@ Dia 40", 40)<br> <br> Application.ScreenUpdating = <SPAN style="color:#00007F">False</SPAN><br> <SPAN style="color:#00007F">ReDim</SPAN> gt(LBound(st) <SPAN style="color:#00007F">To</SPAN> <SPAN style="color:#00007F">UBound</SPAN>(st))<br> <SPAN style="color:#00007F">ReDim</SPAN> t(1 <SPAN style="color:#00007F">To</SPAN> 40) <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN><br> <SPAN style="color:#00007F">With</SPAN> Range("A4", Range("A" & Rows.Count).End(xlUp)).Resize(, 18)<br> Application.DisplayAlerts = <SPAN style="color:#00007F">False</SPAN><br> .Subtotal GroupBy:=1, Function:=xlSum, TotalList:=Array(2), _<br> Replace:=True, PageBreaks:=False, SummaryBelowData:=<SPAN style="color:#00007F">True</SPAN><br> Application.DisplayAlerts = <SPAN style="color:#00007F">True</SPAN><br> lr = Range("A" & Rows.Count).End(xlUp).Row<br> a = .Offset(-.Row + 1).Resize(lr).Value<br> i = .Row<br> <SPAN style="color:#00007F">Do</SPAN><br> i = i + 1<br> <SPAN style="color:#00007F">If</SPAN> a(i, 3) = "" <SPAN style="color:#00007F">Then</SPAN><br> <SPAN style="color:#00007F">ReDim</SPAN> strw(LBound(st) <SPAN style="color:#00007F">To</SPAN> <SPAN style="color:#00007F">UBound</SPAN>(st))<br> <SPAN style="color:#00007F">For</SPAN> c = <SPAN style="color:#00007F">LBound</SPAN>(st) <SPAN style="color:#00007F">To</SPAN> <SPAN style="color:#00007F">UBound</SPAN>(st)<br> <SPAN style="color:#00007F">If</SPAN> IsNumeric(st(c)) <SPAN style="color:#00007F">Then</SPAN><br> strw(c) = t(st(c))<br> gt(c) = gt(c) + t(st(c))<br> <SPAN style="color:#00007F">Else</SPAN><br> strw(c) = st(c)<br> gt(c) = st(c)<br> <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">If</SPAN><br> <SPAN style="color:#00007F">Next</SPAN> c<br> <SPAN style="color:#00007F">ReDim</SPAN> t(1 <SPAN style="color:#00007F">To</SPAN> 40) <SPAN style="color:#00007F">As</SPAN> <SPAN style="color:#00007F">Long</SPAN><br> <SPAN style="color:#00007F">With</SPAN> Cells(i, 1).Resize(, 18)<br> .Font.Bold = <SPAN style="color:#00007F">False</SPAN><br> .RowHeight = 25<br> .Value = strw<br> <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">With</SPAN><br> <SPAN style="color:#00007F">Else</SPAN><br> t(a(i, 3)) = t(a(i, 3)) + a(i, 18)<br> t(1) = t(1) + a(i, 18)<br> <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">If</SPAN><br> <SPAN style="color:#00007F">Loop</SPAN> <SPAN style="color:#00007F">While</SPAN> i < lr - 1<br> <SPAN style="color:#00007F">With</SPAN> Cells(lr, 1).Resize(, 18)<br> .Font.Bold = <SPAN style="color:#00007F">False</SPAN><br> .RowHeight = 25<br> .Value = gt<br> .Cells(1, 1).Value = "Grand Total"<br> <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">With</SPAN><br> .EntireColumn.AutoFit<br> .Resize(lr).RemoveSubtotal<br> <SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">With</SPAN><br> Application.ScreenUpdating = <SPAN style="color:#00007F">True</SPAN><br><SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">Sub</SPAN><br></FONT>