What i'd like to do, is write a VB macro that will scan the entire column (Column F) searing for "Year Total:" and then insert an entire row below it.
I have this:
Sub Macro2() ' ' Macro2 Macro ' ' Keyboard Shortcut: Ctrl+a
Dim C As Variant
Dim FirstRow As Integer
With Worksheets(1).Range("F1:F4000")
Set C = .Find("Year Total:", LookIn:=xlValues)
If Not C Is Nothing Then
FirstRow = C.Row
Do
C.Offset(1, 0).Insert Shift:=xlDown
Set C = .FindNext(C)
Loop While Not C Is Nothing And C.Row <> FirstRow
End If
End With
End Sub
However, it only adds cells in, not an entire row.
I'd also like to add into the code, for it to also search for "Grand Total:" in the same column and add three rows under it as well. I was just going to write two scripts, however if I can mash them all together in one, that would be excellent.