` Printed Icetips Article

Icetips Article



Icetips Products: Icetips Previewer - Select printer before printing
2004-01-08 -- Arnor Baldvinsson
 
In the Icetips Previewer, version 1.100 and above, there are templates that enable printer selection at runtime. This allows your users to print to a different printer than was originally selected for the report.
 
This is very simple to do. Once you have created your Icetips Previewer procedure, you need to apply one global extension template and then an extension template to the Previewer procedure.
 
Here are the steps needed to add the Printer Selection:

1.  Add the "Icetips Previewer - Enable Printer Selection (Global)" 
    Global template.

2.  Add the "Icetips Previewer - Enable Printer Selection" template to the
    previewer procedure.

3.  On the previewer window create a button or a menu item to select a
    printer if you want the user to be able to select the printer separately.

4.  In that button or menu item accepted embed put:

   Do ITPSelectPrinter

5.  Alternatively add this code as the first line in the Accepted code for the
    "File|Print" and the ?PrintAllButton button and the ?PrintOneButton
    button.  I.e anywhere you would like to select a printer before printing.
So basically by just calling Do ITPSelectPrinter you are setting the printer to be printed to. If you need to, you can reset the printer back to it's original by using:
Loc:CurrentPrinter = Loc:OriginalPrinter
The Loc:CurrentPrinter will always hold the destination printer. Loc:OrginalPrinter will always hold the original destination printer, i.e. the printer the report was sent to.
 
This option does not allow you, in it's current incarnation, to print to the selected printer and keep previewing. I will see about adding that option before next release:)



Printed November 21, 2024, 12:06 pm
This article has been viewed/printed 35259 times.
Google search has resulted in 13 hits on this article since January 25, 2004.