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

ReportViewer Navigation

6 Answers 101 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Derek
Top achievements
Rank 2
Derek asked on 19 Jan 2012, 05:33 PM
I am having trouble using the navigation with the Telerik.ReportViewer.WPF Q3 2011.  I am using the MVVM design pattern and passing a reference of the reportviewer to the viewmodel.  In response to a click event a customer dataobject is constructed and populated and feed as the data source to a new distribution report.  The new distribution report is then set as the value for the reportviewer.  However as different versions of the report are ran they are not viewable through the navigation buttons.  How can I accomplish this?

 

var products = Products.Where(x => x.IsSelected);

Custom business object

DistributionCompilation distribution = new DistributionCompilation();

Populating the business object

distribution.BuildSingleBrandDistributionRport(products, SelectedStart, SelectedEnd, MinBottles, NoBuyPeriod, SelectedBrand.Name);

Setting it as the source for the report

NewDistributions distribution_report = new NewDistributions();

distribution_report.DataSource = distribution.ShowReport();

_View.Report = distribution_report;


6 Answers, 1 is accepted

Sort by
0
IvanY
Telerik team
answered on 24 Jan 2012, 05:25 PM
Hi Derek,

The navigation buttons are used to navigate between the pages in the current report and not between reports. If you need navigation between reports you can add them to a Report Book, more information you can find in our Report Book help article.

Regards,
IvanY
the Telerik team

Q3’11 of Telerik Reporting is available for download. Register for the What's New in Data Tools webinar to see what's new and get a chance to WIN A FREE LICENSE!

0
Malcolm
Top achievements
Rank 1
answered on 13 Nov 2012, 05:54 PM

Hello! I am wondering if there is a page navigation event I can utilize. I have a need to update the parameters on a sub-report based on the page displayed in the main report. Being able to update my parameters as the user flips pages would be ideal.

Thanks!

Malcolm

0
Steve
Telerik team
answered on 16 Nov 2012, 11:49 AM
Hi Malcolm,

What you want to achieve would happen automatically if you have wired the SubReport as detail report i.e. it would get the value of each record from the master result set and display value accordingly. See How-To: Creating Master-Detail Reports Using SubReports help article for more information.

All the best,
Steve
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Malcolm
Top achievements
Rank 1
answered on 16 Nov 2012, 08:00 PM
Steve - thanks so much for the help. I actually found that article a couple days ago and was able to get things going as I wanted except I am having an issue with one of my subreports. When I run it as a stand alone report, it shows data as expected, but if I stick into a master report as a subreport...I refuses to return any data. Any suggestions?
0
Steve
Telerik team
answered on 20 Nov 2012, 11:42 AM
Hi Malcolm,

Most likely it does not receive data from the master report. Check that the Parameters property of the SubReport is correctly wired so that its report parameter has as value a field from the master report.

Kind regards,
Steve
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Malcolm
Top achievements
Rank 1
answered on 28 Nov 2012, 08:22 PM
Steve - I found a solution to my problem and posted it here; http://www.telerik.com/community/forums/reporting/telerik-reporting/subreport-will-not-show-any-data-but-shows-data-as-a-stand-alone.aspx#2393020 for others to see.

Thanks everyone! Great product!

Malcolm
Tags
General Discussions
Asked by
Derek
Top achievements
Rank 2
Answers by
IvanY
Telerik team
Malcolm
Top achievements
Rank 1
Steve
Telerik team
Share this question
or