Home Devices
New Blog Posts: Merging Reports - Part 1 and Part 2

Printers problems using Citrix

edited January 2008 in Devices
Hi, we are using RB with the TExtraDevices options, also the application is
running at a Citrix environment.

The problem is that the user has a list of 20 or more diferentes printers,
and not all of them are listed on the print dialog when trying to print a
report out of the application.
They install an MS Office aplication and they can see all of theirs
availables printers, just on our application not all of them are visible.
What could be the problem? Or how could we discard that is the RB the one
with the problem?

thanks a lot for your help.

Eugene Abraham

Comments

  • edited January 2008
    Hi Nico

    I have also experienced this on Terminal Services - I have nothing specific
    I can add except that certain drivers seem allergic to citrix, often if you
    exit the application and then re enter missing printers become available.

    It is so random I have not bothered to report this.

    A colleague who experiences this frequently is just saying to me that this
    proves he is not the only one this happens to.

    Regards

    PLJ

  • edited January 2008
    Hi Eugenio,

    Most problems dealing with a terminal service such as Citrix deal with user
    access. You need to be sure you have complete access to all the printer
    drivers available. ReportBuilder constructs a list of available printers
    using the Windows API DEVMODE structure so if RB can't see or access the
    printers, neither can the Windows API.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited January 2008
    Hi

    I have just completed a small timing exercise, I ran Terminal Services and
    imediately logged on to my application, I could see 6 printers.

    I then logged off my application and waited 5 minutes (still connected to
    TS).

    I then logged on to my application and could see 8 printers.

    The problem sounds like its due to the time it takes Windows to build up a
    printer list?

    Regards

    PLJ


  • edited January 2008

    RB is using the Windows API function EnumPrinters to build the list of
    available printers. See ppPrintr.pas, the method
    TppPrinterList.BuildPrinterList.

    Like many Windows API functions there are many ways to call this function.
    RB is using the Level 4 structure with the options PRINTER_ENUM_CONNECTIONS
    or PRINTER_ENUM_LOCAL. This is recommended by the Windows API docs.

    According to the Win API docs this is the best setting to use for speed.
    Other settings cause each printer to be opened - very slow.

    According to the Win API docs, the call we are using will enumerate the
    locally installed printers, plus printers to which the user has made
    previous connections. (I think it does this by reading the windows
    registry).


    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited January 2008
    The only thing I would add is that I recall having to change some settings
    relating to how printers are re-connected when a remote session logs in. I
    can't remember the exact details but it's along the lines of either
    connecting them all at log on or connecting the printer only when you access
    it.

    The other point is that the printers may be added or installed as normal for
    each user but can also be auto created from those discovered on the network.
    This isn't so good when lots of clients are sharing their printers attached
    to their PC. Also problematic when not all the PC's are actually switched
    on.

    I seem to recall that setting the default printer correctly helped alleviate
    the problems.

    Regards, Paul.



  • edited January 2008
    Paul,

    Thanks for the providing the tips!

    (We do not have any Citrix experience here)

    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited January 2008
    I had like problem more year back and wrote about her here earlier.
    "citrix' complements the printers to uncared-for process in background
    (parallel). So you may see not all printers. I happened to little remake
    the form (ppPrvDlg.pas) of the choice of the printer. I have copied the
    form (ppPrvDlg.pas/dfm) and has added the button "Refresh Printers"...



    --- posted by geoForum on http://delphi.newswhat.com
This discussion has been closed.