Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Odd behavior of PrintOptions.CopyFrom

Hello, All.

I am currently developing a C# app, framework 3.5, using CR 11 R2.

What is going on is that I am showing the standard windows Print Dialog, and attempting to print a report.

Code snippet:

reportDocument.FileName = Path.Combine(filePath, fileName);

reportDocument.PrintOptions.CopyFrom(printOptions.PrinterSettings, printOptions.PageSettings);


printOptions.PrinterSettings.Collate, printOptions.PrinterSettings.FromPage,


The odd behavior is in the call to CopyFrom.

It does not pull all of the settings after the first call. Specifically, it is not getting the duplex or printer name. While debugging it, I have dicovered that a second call to CopyFrom with the same parameters will result in it getting the rest of the settings.

So, the standard battery of questions from someone very confused:

Has anyone encountered anything like this before?

Do you have any idea as to why it is doing this?

Can you think of a more elegant solution/workaround than calling to CopyFrom twice?

Thank you in advance!

-Stephen Erickson

Former Member
Not what you were looking for? View more on this topic or Ask a question