Newsgroups : Borland : borland.public.delphi.rtl.win32 : 2005 Mar : Default network printer over citrix not recognized
| Subject: | Default network printer over citrix not recognized |
| Posted by: | noma..@sorry |
| Date: | Wed, 30 Mar 2005 21:12:51 GMT |
Hi!
Our client encountered a problem with printing from delphi app over
citrix. When default printer is set to network printer then printers
unit does not recognize it and there is exception that no default
printer is selected. When microsoft office application is started the
same way over citrix it recognizes default printer OK. When local
printer is set as default printer then there is no problem with delphi
app.
We use Delphi 4.
It is not easy for us to debug under citrix environment for now. Have
someone encountered such a problem or is there some suggestion?
I have looked into the printers delphi unit and thought about the
following: the problem have to be in the SetToDefaultPrinter method
that is not able to locate default printer and then raises exception
1. probably because EnumPrinters failes to list the network default
printers, I thought about using LEVEL 4 instead of LEVEL 5 to query
EnumPrinters...
2. or I have noticed that delphi 7 changed one line of code in that
method and does
if AnsiSameText(TPrinterDevice(Objects[I]).Device, Device) then
instead of delphi 4
if TPrinterDevice(Objects[I]).Device = Device then
Whould 1 or 2 solve my problem or there is some other sollution,
please help?
tomi.