Answers for "Excel VBA PDF sheet and save to file path from cell"

VBA
0

Excel VBA PDF sheet and save to file path from cell

Sub GetFilePath_Click()

Dim FileAndLocation As Variant
Dim strPathLocation As String
Dim strFilename As String
Dim strPathFile As String
strPathLocation = Worksheets("05282017").Range("D3").Value
strFilename = Worksheets("05282017").Range("D2").Value
strPathFile = strPathLocation & strFilename
FileAndLocation = Application.GetSaveAsFilename _
(InitialFileName:=strPathLocation & strFilename, _
filefilter:="PDF Files (*.pdf), *.pdf", _
Title:="Select Folder and FileName to save")
'This is the concatenated value of selected folder location and filename
MsgBox FileAndLocation

 

End Sub
Posted by: Guest on March-02-2020

Code answers related to "Excel VBA PDF sheet and save to file path from cell"

Code answers related to "VBA"

Browse Popular Code Answers by Language