Hello KIX-Community,

I have a problem with my KIX script and I hope that some of you can help me solving this problem.

I use the Method "AddPrinterConnection" to connet a shared Printer from a central Printserver during user logon.

What happens is, the printer gets connected 99% of the time, but in 1%, the printer simply does not get connected.

I want to fix this and my first thought was, to simply catch the @ERROR value after the printer connection and do a second attempt.

while @ERROR <> 0
AddPrinterConnection()
loop

This is causing problems when a printer simply cannot be connected at all (when server is down, printer configuration wrong etc.)

How would you tackle such a problem?

thank you very much in advance for your thoughts and best regards
Martin