Might have been helpful if you provide sufficient information in the first post !!
UNTESTED, as I don't have the last row in H or the ref3 variable
VBA Code:Sub MM1() With ActiveSheet.PageSetup .DifferentFirstPageHeaderFooter = True .FirstPage.CenterFooter.Text = "" .LeftFooter = Format(Now(), "mmmm d, yyyy") .CenterFooter = ref3 & " " & Chr(10) & .Range("H" & lr).Value End With End Sub
Sub MM1()
Dim lr As Long
lr = Cells(Rows.Count, "G").End(xlUp).Row
With ActiveSheet.PageSetup
.DifferentFirstPageHeaderFooter = True
.FirstPage.CenterFooter.Text = ""
.LeftFooter = Format(Now(), "mmmm d, yyyy")
.CenterFooter = ref3 & " " & Chr(10) & .Range("H" & lr).Value
End With
End Sub
Sub MM1()
Dim lr As Long, r As Range, s As Long, c As Range
lr = Cells(Rows.Count, "H").End(xlUp).Row
s = 1
For Each r In Range("H1:H" & lr)
If r.Offset(0, -1).Value = "Total incl. GST" Then
With r
.Formula = "=sum(r" & s & "c:r" & r.Row - 1 & "c)"
End With
End If
Next r
With ActiveSheet.PageSetup
.DifferentFirstPageHeaderFooter = True
.FirstPage.CenterFooter.Text = ""
.LeftFooter = Format(Now(), "mmmm d, yyyy")
.CenterFooter = ref3 & " " & Chr(10) & .Range("H" & lr).Value
End With
End Sub
Sub MM1()
Dim lr As Long, r As Range, s As Long, c As Range
lr = Cells(Rows.Count, "H").End(xlUp).Row
s = 1
For Each r In Range("H1:H" & lr)
If r.Offset(0, -1).Value = "Total incl. GST" Then
With r
.Formula = "=sum(r" & s & "c:r" & r.Row - 1 & "c)"
End With
End If
Next r
With ActiveSheet.PageSetup
.DifferentFirstPageHeaderFooter = True
.FirstPage.CenterFooter.Text = ""
.LeftFooter = Format(Now(), "mmmm d, yyyy")
.CenterFooter = ref3 & " " & Chr(10) & Range("H" & lr).Value
End With
End Sub