Hello ,
I'm having a button which launches a macro to create a pdf file as output.
When clicking the button Is it possible to:
First select a range, which will be in the output range for my pdf file.
When range selected: choose where to save the file.
I managed the first one, but is saved in a fixed location( " C:\User... etc ) with this code:
So i am looking for a solution Filename: = the possibility to choose where to save the file
Many thx already
I'm having a button which launches a macro to create a pdf file as output.
When clicking the button Is it possible to:
First select a range, which will be in the output range for my pdf file.
When range selected: choose where to save the file.
I managed the first one, but is saved in a fixed location( " C:\User... etc ) with this code:
VBA Code:
Option expliciet
Sub Ritten_AsPDF()
Dim defined_rng As Range
Set defined_rng = Application.InputBox(Prompt:= _
"Choose the Specific Range", Title:="Microsoft Excel", Type:=8)
defined_rng.ExportAsFixedFormat Type:=0, _
Filename:="C:\Users\Dirk\Downloads\" & "Ritten", _
Quality:=0, IncludeDocProperties:=False, IgnorePrintAreas:=False, _
openafterpublish:=True
End Sub
So i am looking for a solution Filename: = the possibility to choose where to save the file
Many thx already