SetPrinterByName() returning false

This forum is the place to discuss issues related to ReportPro, Xs2Ado, Vo2Ado, bBrowser and other 3rd party products
Post Reply
MJI
Posts: 14
Joined: Wed May 24, 2023 11:58 am

SetPrinterByName() returning false

Post by MJI »

Hello All

Everytime something like this happens I bemoan that the source was not purchased!!!!

We are getting a false from SetPrinterByName() with a printer name of 'Print&Share'.

It is installed and we have never had issues changing to different printers before.

Our VO program can print to it, but not auto select using SetPrinterByName

IF SELF:oPrinter:SetPrinterByName(cPrinter)

Any ideas please?
User avatar
robert
Posts: 4225
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

Re: SetPrinterByName() returning false

Post by robert »

Martin,
Is this for RP2?

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
MJI
Posts: 14
Joined: Wed May 24, 2023 11:58 am

Re: SetPrinterByName() returning false

Post by MJI »

Hello Robert, yes it is RP2.

Oh and we think it is the customer IT setup rather than ReportPro, it is on RDS but works on every other site we have tried, high hundreds every day.

Actually this is the first time auto printer queue selection has failed.

Support is trying 2.30 and 2.36.

To be honest I am not too up on Window printing except it works. (I am of the age of Netware queues and HP Laserjets).

I get the name from Windows, using some code I was given using EnumPrinters(). Then stored in a DBF using a specific field.

The user presses the button then I use the stored name in SetPrinterByName()

What conditions would cause to to return false?

Could it be rights?

Thanks

Martin
Post Reply