Well... I've managed to isolate the problem.Roberto Lopez wrote: I'm trying to print in network printers from Windows 7 machines.
The program simply stop responding and the most amazing thing, is that the entire system stop responding too.
I've tested from two different (brand new) Windows 7 PCs and with different networked printers with the same results.
The command I've used initially was:
SELECT PRINTER DEFAULT
Then, I've changed to:
SELECT PRINTER DIALOG
And... Voila!... it is working now.
Since the problem arises on Win7 clients only (XP clients of the same network/same printer works fine) it is obviously related to Win7.
SELECT PRINTER DEFAULT gets the printer name from GetDefaultPrinter() function, so, the problem could be that the printer name is incorrectly returned by this function or incorrectly received by _HMG_PRINTER_SetPrinterProperties() (low level C function that handles SELECT PRINTER <cPrinter> | DEFAULT command).
The fact that the printer is a 'network printer' that is directly connected to a switch, could be related to this too and it could be the reason because nobody reported this yet.
I'll still researching...