User login

Languages

Donate

Donate for a MSI Installer Package [more]

Target:
$ 1200
Achieved:
$ 1036.55
Fees:
$ 52.53
86.4 %
Donate
SourceForge.net Logo

Pdfcreator to a [file].pdf via Visual basic from Excel

No replies
caseman
User offline. Last seen 16 weeks 5 days ago. Offline
Joined: 10/22/2009

To start - I am fairly new at VB so please excuse the crudeness of my explaination and this routine. That said : I am attempting to send and save an electonic prinout (trying to be green) to a folder via a local network. when I run the following routine it does everything that I want, but the format that it end up in is PS instead of a PDF. Is this a Pdfcreator setting or am I going about this the wrong way?

Thanks for any help anyone can offer

 

 

Sub sendPdf()
'
' sendPdf Macro
' Macro recorded 10/15/2009 by Casenet User
'
Dim Partno As String
Dim destination As String
Dim PrintLocation As String
Dim extension As String

extension = ".pdf"
destination = "L:\upload\finished_baz_validations\"
Partno = Range("A4").Text

PrintLocation = destination & Partno & extension

If Range("A4").Value = ("PART NUMBER HERE") Then
     Beep
     MsgBox ("Please Complete Form before submitting")
    Else
    If Range("J4").Value = True Then

       Range("A1:I34").Select
       ActiveSheet.PageSetup.PrintArea = "$A$1:$I$34"
       ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:="PDFCreator on Ne00:", PrintToFile:=True, Collate:=True, PrToFileName:=PrintLocation
            
   Else
       MsgBox ("Please Fill in required measurements including your Operator ID and BAZ ID")
 
    End If
End If

    End Sub

__________________

Caseman

© pdfforge.org :: Contact us :: Sitemap :: Design by Daniela Martin

Validate XHTML or CSS.