Guys,
I need your help. I am trying to save each Pagebreak in "Sheet 1" as separate files into a folder as PDF. The summary is running of a pivot so its dynamic depending on the number of people asking for payments. I would like to name each PDF based on the customer name given Column B first cell in each page break.
So far, I only have codes to export the entire file as PDF.
Sub SaveasPDF()
Dim filename As String
With Worksheets("My Sheet")
filename = Range("A1")
'& .Range("A2").Value & .Range("A3").Value
End With
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, filename:= _
"C:\Users\DPhilip\Desktop\Test Folder\" & filename, Quality:=xlQualityStandard, _
IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=False
End Sub
Thank you so much for any help. I really appreciate it.
I need your help. I am trying to save each Pagebreak in "Sheet 1" as separate files into a folder as PDF. The summary is running of a pivot so its dynamic depending on the number of people asking for payments. I would like to name each PDF based on the customer name given Column B first cell in each page break.
So far, I only have codes to export the entire file as PDF.
Sub SaveasPDF()
Dim filename As String
With Worksheets("My Sheet")
filename = Range("A1")
'& .Range("A2").Value & .Range("A3").Value
End With
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, filename:= _
"C:\Users\DPhilip\Desktop\Test Folder\" & filename, Quality:=xlQualityStandard, _
IncludeDocProperties:=True, IgnorePrintAreas:=False, OpenAfterPublish:=False
End Sub
Thank you so much for any help. I really appreciate it.