Hello,
Please could I have some assistance with this macro.
I need to convert sheets into individual pdfs. The macro works to a point and then just stop converting the sheets and states Run time Error '5': Invalid procedure call or argument . Below is the code.
Sub SaveAsPDFOptions()
Dim Folder_Path As String
With Application.FileDialog(msoFileDialogFolderPicker)
.Title = "Select the Folder Path"
If .Show = -1 Then Folder_Path = .SelectedItems(1)
End With
Dim sh As Worksheet
Application.ScreenUpdating = False
For Each sh In ActiveWorkbook.Worksheets
sh.ExportAsFixedFormat xlTypePDF, Folder_Path & Application.PathSeparator & sh.Name & " Nov 24.pdf"
Next
Application.ScreenUpdating = True
End Sub
Much appreciated,
Kind regards,
Sheila
Please could I have some assistance with this macro.
I need to convert sheets into individual pdfs. The macro works to a point and then just stop converting the sheets and states Run time Error '5': Invalid procedure call or argument . Below is the code.
Sub SaveAsPDFOptions()
Dim Folder_Path As String
With Application.FileDialog(msoFileDialogFolderPicker)
.Title = "Select the Folder Path"
If .Show = -1 Then Folder_Path = .SelectedItems(1)
End With
Dim sh As Worksheet
Application.ScreenUpdating = False
For Each sh In ActiveWorkbook.Worksheets
sh.ExportAsFixedFormat xlTypePDF, Folder_Path & Application.PathSeparator & sh.Name & " Nov 24.pdf"
Next
Application.ScreenUpdating = True
End Sub
Much appreciated,
Kind regards,
Sheila