Print Settings for ReportViewer pogrammatically
-
Hello I'm developing a project with C# 2010. I want to set paper size and layout programmatically. But it doesnt work properly. There is no usefull document at the web. Regards
-
Hello I'm developing a project with C# 2010. I want to set paper size and layout programmatically. But it doesnt work properly. There is no usefull document at the web. Regards
Please be specific. Let us know what you have tried with a piece of code and what error you got.
Praveen Raghuvanshi Software Developer
-
Please be specific. Let us know what you have tried with a piece of code and what error you got.
Praveen Raghuvanshi Software Developer
Thank you. I created my Report and i can see it at run time, But for printing, everytime user should open printer settings and change the paper size. i want to set paper size at design time and print the report programmatically. I wrote below code (doesnt work):
this.reportViewer1.PrinterSettings.DefaultPageSettings.PaperSize.Height = 1169; this.reportViewer1.PrinterSettings.DefaultPageSettings.PaperSize.Kind = PaperKind.A4Extra; //Error, Kind is Read-Only this.reportViewer1.RefreshReport();
Also i couldn't find PrintReport option for ReportViewer.