I have a macro with the following code:
Private Sub Btn_SavePDF_Click()
Dim Filename As String
Application.DisplayAlerts = False
template_file = ActiveWorkbook.FullName
Filename = ActiveCell.Value
filesavename = Application.GetSaveAsFilename( _
InitialFileName:="C:\" + Filename + ".pdf", _
fileFilter:="PDF Files (*.pdf), *.pdf")
If filesavename = False Then
Exit Sub
End If
FilePath = filesavename
file_name_saved = ActiveWorkbook.FullName
ActiveWorkbook.ExportAsFixedFormat Type:=xlTypePDF, Filename:=filesavename, _
Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _
OpenAfterPublish:=False
Application.DisplayAlerts = True
End Sub
The macro prompts the user to save the file to computer. When the OK button is clicked, it presents the "Invalid Procedure Call Or Argument" error message. I believe this has something to do with the specific computer. This code works on other systems (deployed this code to 10 different machines and this is the only one with this issue).
Any ideas?
Bookmarks