I have a MS Access table with invoice information in it
When I select an invoice in a form (with two print buttons) I want the option of printing to either the “Till Slip Printer?? or to the Big Laze Printer?? by clicking on either the “Big Invoice?? or the “Small Invoice “buttons on the same invoice form.
The “Big Invoice?? button opens a report with the name of “BigInvoice?? and
The “Small Invoice?? button opens a report with the name of “SmallInvoice??
(Both report has the same information but with different layouts)
The available printers to be used must only be read from a [login to view URL] file in the same folder as the MS Access project.
The [login to view URL] file looks like this
=================================
[LastP]
LPName=BIG
[Big]
BPName=Canon MF3110
BPDriver=winspool
BPort=Ne02:
[Slip]
SPName=HP LaserJet 4
SPDriver=winspool
SPort=LPT1:
[PrintNow]
NPName=BIG
=================================
The [LastP] area in the [login to view URL] file denotes the last printer I printed to, if it’s the same as [PrintNow] the default printer need not change “for obvious reasons??
But if they are not the printer under [Big] should be used as the default printer before the report “BigInvoice?? is called, and the printer under [Slip] should be used as the default printer before the report “SmallInvoice?? is called. .
In short we do not need to get the printer information from windows we only need to change the default printer momentarily to whatever is in the [login to view URL] file when pressing either “BigInvoice?? or SmallInvoice??.