We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Dynamic printing of a PDF label into multiple pages

I have made a barcode label in PDF. It is designed to be printed in 15 labels per page, so if the label count exceeds 15 then it has to automatically be printed into another page.  How can I dynamically separate the labels into 15 piece blocks so as to be able to print them properly into the label printer.  Is this something that needs to be controlled through printer settings or PDF properties.  Below is a sample PDF of the labels.  This was actually up to 45 pcs. but was cut short due to the page size that I defined.  



And that is one more thing, I am having difficulty fitting the actual page size to the label size.   If the 15 label block size is for example 55m by 40mm, how should I size the PDF page to fit this label block size properly?



Currently I print only in 15 pc blocks at time but this is cumbersome and time consuming when printing for example 5K pcs of labels.  By the way, the individual labels are serialized.

Appreciate any help or suggestions.

1 Reply

SL Sowmiya Loganathan Syncfusion Team February 9, 2020 11:38 AM UTC

Hi San,  
 
Thank you for contacting Syncfusion support.  
 
We have analyzed your query. Based on your requirement, we have created the sample to print the 15 barcode label per page in PDF document. Please find the sample for the same from below,  
 
 
Note: We can modify the width and height of the PDF document as per the barcode labels size. Please refer the below code snippet,  
 
//Creating new PDF Document 
PdfDocument doc = new PdfDocument(); 
 
//Change the document size  
doc.PageSettings.Width = 400; 
doc.PageSettings.Height = 600; 
 
Please try the above sample in your end and let us know if your requirement is achieved or not.  
 
Regards, 
Sowmiya Loganathan 
 


Loader.
Live Chat Icon For mobile
Up arrow icon