Dear,Very strange is the way of using AddPrinterConnection and SetDefaultPrinter.
To set the printer default in a correct way the printer should exist. In
your code you add two different printers which doesn't match the default
printer.
The see the actual problem use following code:
code:
IF Ingroup("Accounting") <>0)
IF (AddPrinterConnection("\\server\AcctHP8") <> 0)
? "Warning KIX-AddPrinterConnection: error @error (@serror)"
ELSE
? "Informative KIX: add printer '\\server\AcctHP8'"
ENDIF
IF (AddPrinterConnection("\\server\Purchasing HP 2250 Color") <> 0)
? "Warning KIX-AddPrinterConnection: error @error (@serror)"
ELSE
? "Informative KIX: add printer '\\server\Purchasing HP 2250 Color'"
ENDIF
IF (SetDefaultPrinter("\\server\Accounting HP 8100") <> 0)
? "Warning KIX-SetDefaultPrinter: error @error (@serror)"
ELSE
? "Informative KIX: set defaultprinter ..."
ENDIF
ENDIF
greetings.