Skip to Content
0
May 27, 2018 at 02:01 PM

Why can't I set CrystalDecisions.CrystalReports.Engine.PrinterName property?

116 Views

In a WinForms application I'm working on, there's a requirement to set the preferred printer from the app regardless the Windows default printer, like this:

reportDocument.PrintOptions.PrinterName = printerName;

but it's not permitted for some reason to set it. initially PrinterName is empty string and after setting it, it still empty and thus using the default windows printer not that stored in printerName.

I found this answer on SO: https://stackoverflow.com/a/24334756/6197785

I followed it once and it worked, but now I can't (when I uncheck the checkbox and click save then opening the dialog again, the checkbox is still checked!)