shippey121
Well-known Member
- Joined
- Mar 21, 2006
- Messages
- 1,003
Morning all
i have a document that prints labels, the label has a template sheet and then VBA code cycles through data to populate each label and prints, if i print directly to the printer everything is fine and it prints in order.
what im wanting to do is print to PDF, i can sort the code to export to PDF but it does each print as a separate PDF and im wanting to combine them, i have tried using a PDF printer rather than exporting but it seems to mix them up and not put them in order, i need them in order, the PDF Printer im using is called PDF Creator, after the print finishes i have all the separate files and choose Merge as excel sends each page as a separate print
as you can see the code to print is pretty simple, any suggestions on how i could create a multi page document from 1 sheet
i have a document that prints labels, the label has a template sheet and then VBA code cycles through data to populate each label and prints, if i print directly to the printer everything is fine and it prints in order.
what im wanting to do is print to PDF, i can sort the code to export to PDF but it does each print as a separate PDF and im wanting to combine them, i have tried using a PDF printer rather than exporting but it seems to mix them up and not put them in order, i need them in order, the PDF Printer im using is called PDF Creator, after the print finishes i have all the separate files and choose Merge as excel sends each page as a separate print
as you can see the code to print is pretty simple, any suggestions on how i could create a multi page document from 1 sheet
Code:
Sub print_labels()
Dim x As Long
Dim y As Long
Dim labels As Integer
On Error GoTo exitsub
x = InputBox("Enter number of Start Pallet")
y = InputBox("Enter number of Pallet Tickets required")
y = y - 1 + x
Sheets("labels").Select
For labels = x To y
Range("F3").Value = labels
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next labels
exitsub:
Sheets("Summary Sheet").Select
End Sub