Telerik Forums
Reporting Forum
7 answers
872 views
Hi there,

After having some issues figuring out how to get multiple reports in a single document, I finally stumbled onto the ReportBook class. 

I have implemented a number of different single page report documents and have, up until now, had no trouble adding them to the book and getting them to display. The issue that I've come across is that I have one derivation of the report that requires three separate instances of a single page, so

public class MultiSheetReport_Group1 : Telerik.Reporting.ReportBook
{
    public MultiSheetReport()
    {
        this.Reports.Add(new CoverPages.GroupOneCoverPage());
        this.Reports.Add(new ItemizedPages.GroupOneItems());
    }
}

now, I have an Group that requires a monthly breakout of the itemized page, so there is a GroupFourItems report that takes in both the id to read as well as the month value that I would like to print that report for.  The issue that I am having is that for each instance of the Monthly Report, the same value is being sent to the ObjectDataSource constructor for the month value.

I've attempted to create another constructor for the MultiSheetReport() like so:

public MultSheetReport(int parentId)
{
    var monthTriplet = DateTimeHelper.GetMonthOrdinals(parentId);
    // monthTriplet is a Tuple of int, int, int
    var cvrPage = new CoverPages.GroupOneCoverPage();
    cvrPage.ReportParameters.Clear();
    cvrPage.ReportParameters.Add(new ReportParameter("id", ReportParameterType.Integer, parentId));
    this.Reports.Add(new CoverPages.GroupOneCoverPage());
    
    var m1ItemPage = new ItemizedPage.GroupOneItems();
    m1ItemPage.ReportParameters.Clear();
    m1ItemPage.ReportParameters.Add(new ReportParameter("id", ReportParameterType.Integer, parentId));
    m1ItemPage.ReportParameters.Add(new ReportParameter("month", ReportParameterType.Integer, monthTriplet.Item1));
    this.Reports.Add(m1ItemPage);
 
    var m2ItemPage = new ItemizedPage.GroupOneItems();
    m2ItemPage.ReportParameters.Clear();
    m2ItemPage.ReportParameters.Add(new ReportParameter("id", ReportParameterType.Integer, parentId));
    m2ItemPage.ReportParameters.Add(new ReportParameter("month", ReportParameterType.Integer, monthTriplet.Item2));
    this.Reports.Add(m2ItemPage);
}

 and so on...
The first problem is that the parameterized constructor for the reportbook is never called as the report, only the default constructor.  This leads to the second issue which is that when I put a breakpoint on the constructor for the ObjectDataSource that backs the ItemizedPage.GroupOneItems report class, the exact same value is passed in for each of the months.  I'm not entirely sure how to fix this.  

Any thoughts?

Thanks.

Todor
Telerik team
 answered on 25 Sep 2019
4 answers
596 views

Hi,

Is there a way to dynamically set the chart height based on the number of data rows? The chart looks fine when there are about 10-12 rows of data, but anything more and it starts to squish to meet the height requirements of the chart. I'm assuming there is a way and I'm just missing it!

I'm using the standalone Telerik Report Designer FYI. I've attached photos for an example.

Neli
Telerik team
 answered on 25 Sep 2019
1 answer
105 views

Hi, I have a report act as a header template as follows:

var template = new TemplateReport{ Header = "Some header"};

where updating the custom properties will also update the textbox value.

When I want to use the template, I will just create the template, and do the such things:

var template = new TemplateReport{ Header = "Some header"};

var content = new ContentReport();

template.Content = content;

 

How can I do such things with report book? Thanks!

Eric R | Senior Technical Support Engineer
Telerik team
 answered on 24 Sep 2019
2 answers
292 views

We have a legacy web application leveraging "Telerik Reporting Q1 2015 SP1 (version 9.0.15.324)" and would like to bring it up to date with the current version "Progress® Telerik® Reporting R2 2019 SP1 (13.1.19.618)".

I have not been able to find anything to indicate what, if any, breaking changes were introduced in more recent versions or any other pitfalls we may face thus it is difficult to plan the effort or weigh the value.

Does anyone know if the newest version is backward compatible with version 9.0.15.324?

Thanks in advance,

Matt

Telerik Reporting Version History: https://www.telerik.com/support/whats-new/reporting/release-history

Missing User
 answered on 23 Sep 2019
1 answer
393 views
Telerik version SP1.11.1.17.614

 
function createSingleSelectEditor(placeholder, options) {
        console.log(placeholder);
            var dropDownElement = $(placeholder).html('<div></div>');
            var parameter,
                  valueChangedCallback = options.parameterChanged,
                  dropDownList;
 
            function onChange() {
                var val = dropDownList.value();
                valueChangedCallback(parameter, val);
            }
 
            return {
                beginEdit: function (param) {
 
                    parameter = param;
 
                    $(dropDownElement).kendoDropDownList({
                        dataTextField: "name",
                        dataValueField: "value",
                        value: parameter.value,
                        dataSource: parameter.availableValues,
                        change: onChange
                    });
 
                    dropDownList = $(dropDownElement).data("kendoDropDownList");
                }
            };
        }
 

@(Html.TelerikReporting().ReportViewer()
            .Id("VisorInformes")
            .ServiceUrl(Url.Content("api/reports/"))
            .TemplateUrl("/Resources/Templates/telerikReportViewerTemplate-FA.html")
            .ReportSource(typeReportSource)
               .ViewMode(ViewMode.Interactive)
            .ScaleMode(ScaleMode.Specific)
            .Scale(1.0)
            .PersistSession(false)
            .PrintMode(PrintMode.AutoSelect)
            .ParameterEditors(p =>
            p.SingleSelectEditor("createSingleSelectEditor"))
Neli
Telerik team
 answered on 23 Sep 2019
2 answers
750 views

Hello,
Can I show a field from a table using a Telerik Reporting HTML TextBox?

 

Claudio
Top achievements
Rank 1
Iron
 answered on 23 Sep 2019
2 answers
4.4K+ views

     Dear Admins.

I'm Developing Application Using Telerik Winform UI R2 2019 SP1. But i was using Microsoft RDLC report's for Printing and Displaying the Results.

But i was to Shift to Telerik Reports.

After spending too much time i was not able to create a single report. Did not find any to the point tutorial for creating report.

I'm Using SqlServer Database.

Please if possible provide any step by step helping material.

thank you

Neli
Telerik team
 answered on 23 Sep 2019
2 answers
297 views
Can I not split my table when exporting a document to PDF? I use telerik.reporting.table element.
Roman
Top achievements
Rank 1
 answered on 23 Sep 2019
1 answer
164 views

I have tried two different machines and the online demos at :  https://demos.telerik.com/reporting/  show only loading report.

I want to show these demos to management so we can evaluate using Telerik reporting.

Are the demos offline?

 

 

Silviya
Telerik team
 answered on 19 Sep 2019
2 answers
327 views

Hi there, 

I'm new to Telerik Reporting and I'm building a report that shows a list of images.  The images are uploaded from a mobile app, processed, and then are made available to be displayed on the report.

In some cases there could be an issue with the processing and the image file is not available or the processing hasn't completed yet before the report is executed.  In this case I would rather display nothing than the big red error message that shows when the image can't be found.  Is there a way for me to suppress this message somehow?

I've attached a sample of the error message.

Thanks for the help,

Greg

Greg
Top achievements
Rank 1
Iron
 answered on 18 Sep 2019
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?