How do I print Multi-Page TIFF files with ImageControls 2.0?
To print a multi-page document, you will need to set DeviceMethod to Batch mode: KPrnt1.DeviceMethod = KPDEVICEMETHODBATCH Setup a global integer variable that will serve as a counter for the purpose of iterating through the pages in the document: Dim p_Counter as integer In the KPrnt BatchStart event, initialize the global counter to 1: p_Counter = 1 In the KPrnt PageStart event, set the PSFilename of the document that you want to print and the PSPage property. The PSPage property sets the page to to print and is set from the global counter. After setting the Filename, and before setting the PSPage property, you will first need to check the PSPageCount property and if the global counter is greater than the PSPageCount then set the Filename to “” which will terminate the batch: KPrnt1.PSFileName = “c:\imgctls\bin\sample1.tif” If p_Counter > KPrnt1.PSPageCount Then KPrnt1.PSFileName = “” Else KPrnt1.PSPage = p_Counter End If Now increment the global counter: p_Counter = p_Counter + 1 If