1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
|
Sub Adobe_PDF()
Dim NomPS, NomPDF, NomLog As String
Dim nom, path, dte As String
Dim PDFm As PdfDistiller
nom = ActiveSheet.Range("E13").Value '& ActiveSheet.Range("C36")
path = "\\*****\partage\"
NomPS = path & nom & ".ps"
NomPDF = path & nom & ".pdf"
NomLog = path & nom & ".log"
ActiveSheet.PrintOut copies:=1, Preview:=False, _
ActivePrinter:="Acrobat PDF on Ne00:", PrintToFile:=True, _
Collate:=True, PrToFilename:=NomPS
Set PDFm = New PdfDistiller
PDFm.FileToPDF NomPS, NomPDF, ""
Set PDFm = Nothing
Kill NomPS
Kill NomLog
End Sub |