This is a migrated thread and some comments may be shown as answers.

Get page size from report viewer

1 Answer 254 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Drobyshev_Meidel
Top achievements
Rank 1
Drobyshev_Meidel asked on 26 Oct 2018, 07:46 AM
Hi. I try to select report engine for my application and play with Telerik reporting. Almost all clear and working as expected.
One question. In what way I can get selected page size, orientation etc in reportViewer?
After call ShowPageSetupDialog for example...

1 Answer, 1 is accepted

Sort by
0
Silviya
Telerik team
answered on 30 Oct 2018, 04:19 PM
Hello Drobyshev_Meidel,

Thanks for your interest in our product.
In order to get report's PageSettings and/or modify from the client side is through report parameters. In case the value of some report property is bound to a report parameter value, changing the value of report parameter from the client side can change the value of the report property.
For example to bind Report.PageSettings.Landscape property to a report parameter, add a binding into Report.Bindings collection - https://www.screencast.com/t/AeGmQp6F.

Report parameters can be changed form the client side using parameters area of the report viewer. Report parameter can also be hidden (will not appear in the viewer's parameters area) and you can pass the value to this parameter using reportSource.parameters option of the viewer:
$("#reportViewer1")
   .telerik_ReportViewer({                 
       serviceUrl: "/api/reports",
       reportSource: {                     
           report: "SampleReport.trdp",
           parameters: { Landscape: true }
       },
     ...

Don't hesitate to ask if you have any questions.


Regards,
Silviya
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
Drobyshev_Meidel
Top achievements
Rank 1
Answers by
Silviya
Telerik team
Share this question
or