try this
![]()
Sub exportToPdf() strFilePath = "D:\test\" Application.ScreenUpdating = False For Each Sh In Sheets strPdfName = Sh.Name & ".pdf" Sh.Copy ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:=strFilePath & strPdfName, _ Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _ OpenAfterPublish:=False ActiveWorkbook.Close (False) Next Application.ScreenUpdating = True End Sub
Bookmarks