Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello,
I´m have earlier made a vba-programming for printing (looping). Now I´m trying to do the same and to save all prints at the same place like pdf. Do anyone know what I have done wrong? I´l be wery grateful for your help. Se my code below. Br Mia Sub Skrivpdftest() ' ' Skriv Makro ' Makrot inspelat 2006-11-28 av F Dim Start As Integer Dim Stopp As Integer Dim SkrivUt As String Sheets("Kunddata").Select Start = Range("C10").Value Stopp = Range("C11").Value For i = Start To Stopp Sheets("Kunddata").Select Range("C12").Value = i SkrivUt = Range("F12").Value If SkrivUt = "S" Then If Dir(Environ("commonprogramfiles") & "\Microsoft Shared\OFFICE" _ & Format(Val(Application.Version), "00") & "\EXP_PDF.DLL") < "" Then FilenameStr = "M:\Försäkringsbevis\" & _ ActiveSheet.Range("b4").Value & ".pdf" Sheets("Faktura").Select ActiveSheet.ExportAsFixedFormat _ Type:=xlTypePDF, _ Filename:=FilenameStr, _ Quality:=xlQualityStandard, _ IncludeDocProperties:=True, _ IgnorePrintAreas:=False, _ OpenAfterPublish:=Prewiev Sheets("Faktura").Select Next Sheets("Kunddata").Select End If End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2003 printing problem--printing 1 document on 2 pages | Excel Discussion (Misc queries) | |||
urgent-looping through data validation list then printing as per each value | Excel Programming | |||
Printing multiple rpts via Looping | Excel Programming | |||
Enable Double sided printing contiuously when printing multiple s. | Excel Discussion (Misc queries) | |||
strange printing/looping problem | Excel Programming |