I create a procedure where I set a printer for special documents, but the print-output will not change to an other printer as my default printer. It founds the criteria, but nothing happens to my printer settings. What do I wrongly?
proc SetSpecialPrinter
lnprinters = Aprinters(laPrinters)
If lnprinters > 0
For lnCounter = 1 to lnPrinters
If ATC('4000', laPrinters(lnCounter,1)) > 0
** Set printer to Name laPrinters(lnCounter,1)
*** or
** Set Printer to Default laprinters(lnCount,1)
Exit
endif
EndFor
endif
proc SetSpecialPrinter
lnprinters = Aprinters(laPrinters)
If lnprinters > 0
For lnCounter = 1 to lnPrinters
If ATC('4000', laPrinters(lnCounter,1)) > 0
** Set printer to Name laPrinters(lnCounter,1)
*** or
** Set Printer to Default laprinters(lnCount,1)
Exit
endif
EndFor
endif