Telerik Forums
Reporting Forum
5 answers
586 views
Before calling my report, I generate a generic list of business objects. The processing is quite complex and I do not want to try to use Telerik's parameter facility to do this. 

How can I pass this List<BusinessObject> to Telerik Reporting at runtime? What do I use as a datasource in order to design the report?

I am using VS2010 and Report Q1 2011.

(Sorry I mis-posted this issue in the Winforms area - could not move it)
Stef
Telerik team
 answered on 28 May 2013
3 answers
204 views
I have a report that has a single parent (Patient) and multiple children (test results, recommendations, background information) with forced page breaks before each section. This is NOT a hierarchy it is distinct sets of information for the patient. 

In other products that I am familiar with you would create multiple detail sections but i understand from reading that this is not supported. I've tried to simulate this feature with groups but there only seems to be one hierarchy of groups. 

I've tried dropping each logical detail section in panels but:
a. there does not seem to be a way to create a page break for a panel
b. keeptogether does not always work as I would expect when the height of the section changes (i.e. if the kept-together section is longer than a page the first lines of it will be pushed to the prior page rather than creating a page break)

I am using report designer and pushing the XML report definitions to a server and then running them from there so assembling a set of subreports is not practical.

Any suggestions would be greatly appreciated.
Don Rule
Translational Software
Stef
Telerik team
 answered on 27 May 2013
3 answers
90 views
Hi Guys,

    I have a strange issue in my web application, when I access the web application from IPAD safari (IOS6) when a telerik report opens for the first time reportviewer opens blank and if I click on next button report loads the next page and then I have to click the previous to see the first page which was blank. im using Telerik Q2 2012 version and this is an urgent issue to fix. I tested on IOS5 IPAD safari version, it works well. Telerik report viewer is loaded on a ASPX page.

Best regards

Shivanka
Stef
Telerik team
 answered on 27 May 2013
6 answers
239 views
Dear all,

How can I bind the report to a data in a MVVM scenario.
I am using PRISM4(MEF), SL, RIA service.

I setup everything for the report to work using the EF connection, How can I do the binding to EF queries from the VM.

Best regards
KS
Top achievements
Rank 1
 answered on 24 May 2013
2 answers
380 views
Hi!

I create a trdx report in Telerik Report Designer. After I added this report to my project.

Telerik.Reporting.UriReportSource uriReportSource = new Telerik.Reporting.UriReportSource();
            uriReportSource.Uri = @"Report\teszt.trdx";
            TelRptViewer.ReportSource = uriReportSource;


I want to add a dataTable to report programatically. So my data is not avalible at design time.
I check some topic in help.
Working With Data at Design Time

"In this case you would have to mock your data just to enable the Report Designer to show any data schema. "
I don't understand this. How it is possible?

I already check this links too.
Using the NeedDataSource event to connect data
How to: Bind to a DataTable

My main problem is the next I don't really know or understand how to set a data-schema in designer.
Thx
Peter
Telerik team
 answered on 24 May 2013
6 answers
1.4K+ views
Hi there,

I really want to let the users know whenever an error or exception occurs while a report is generated. I use a ReportViewer to display my reports and I have an errorlabel placed above the viewer.

It is possible, due to rights, that a user cannot retrieve certain data and therefore the viewer throws an error message, but I want to show an "informative" message in an errorlabel outside the report, above the viewer itself on the .aspx page. Whenever this error or exception occurs I want to NOT generate the report (just abort it and show no report) and display corresponding error message in the errorlabel on the aspx page.

In my code-behind of my .aspx page I have the following:
CustomReport customReport = new CustomReport();
// ...set reportparameters...
this.ReportViewer.Report = customReport;
// report is getting generated and viewer shows an error

For all of you, I don't use a ReportProcessor, so the Error event of it cannot be used. The Error event of the report itself cannot be used as well, because it's located in another DLL and not accessible in my .aspx page. So why isn't there an event such as the Error event of the ReportProcessor and report for the ReportViewer? 

I really want to solve this, because I don't want to show the users a report with only an error in it. I don't want to show the report at all if an error/exception occurs and this error/exception details should be displayed in the errorlabel.

Looking forward to a solution or workaround! Thanks in advance!

Regards,
Datamex
Mukul
Top achievements
Rank 1
 answered on 24 May 2013
5 answers
88 views
Hi,
       I am using Telerik reporting in my pages. I get an Script error in ie9, ie10 on loading a report viewer inside the radwindow as 'Array' is undefined. Can you please provide me a working solution






Thanks
Stef
Telerik team
 answered on 23 May 2013
3 answers
82 views
We are developing a reporting system for an enterprise web application.  The report definitions (*.trdx) are all being built using the stand alone Telerik Report Designer so there is no code behind pages associated with the definition files. One of the business requirements is to save sets of parameter values for each report.  I have devised a way to show just the parameters area of a report, but I am not able to access the values set by the user.  All the documentation and other forum threads state that I should be able to hook up listeners to the ReportDocument ItemDataBinding and ItemDataBound events.  I have done that, but the event handlers are not being triggered when a user sets a value and the report viewer refreshed the data.

Here is the setup:
  • A report viewer object is added to an .aspx page (C#).
  • In the code behind, the report definition file is loaded, deserialized and attached to the report viewer via the ReportSource        

   var reportDefinitionFile = Server.MapPath(
"~/app/reports/repository/rpt/" + _reportPath);
  
   var xmlSerializer =
new ReportXmlSerializer();
   reportDocument = (Telerik.Reporting.Report)xmlSerializer.Deserialize(reportDefinitionFile);
   var reportSource =
new InstanceReportSource();
   reportSource.ReportDocument = reportDocument;
   trdParameters.ReportSource = reportSource;

      trdParameters is the report viewer control.  reportDocument is a private variable at the Page level and has been hooked up the listener reportDocument_ItemDataBound:
protected override void OnInit(EventArgs e)
{
    reportDocument.ItemDataBound += new EventHandler(reportDocument_ItemDataBound);
 
    base.OnInit(e);
}
 
private void reportDocument_ItemDataBound(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.Report rpt = (Telerik.Reporting.Processing.Report)sender;
    var obj = rpt.Parameters;
}

When the page is called, the parameters are rendered properly and the report generates properly but event handler is never triggered. Any time a user changes a parameter, the report viewer makes an AJAX call to the Telerik reporting dll and I cannot find a way to intercept that.

I am using Q1 2013 version of Telerik Reporting.

Any ideas?
Unknown
Top achievements
Rank 1
 answered on 23 May 2013
3 answers
117 views
Hi there, this is the structure of my data
{int id, int ring, string phase} where id=1, 2, ..., 16, ring=1,2,3,4, phase = short string 

The report I want is shown on desired_report.gif

What you see in the boxes are
|=============================
| Sequence - {id}                               | <==== title of the box 
=============================
| Ring {ring}        |   {phase}               | <==== this section grows vertically (per id/sequence)
=============================

I tried doing something similar without much success all I've got is this report shown in havethis_report.gif
the layout of the report (design mode) is shown in layout_report.gif

the structure of the report is shown in explorer_report.gif

for the list lstDetailData I have the following :
row group expression: "(Field.Ids+Fields.Ring-2)%32"
column group expression: "(Field.Ids+Fields.Ring-2)/32"

What occurred to me is to hide the title every four elements like this:
            textBox4.Bindings.Add(new Binding("Visible", "= Fields.Ring = 1"));
            txtId.Bindings.Add(new Binding("Visible", "= Fields.Ring = 1"));

but you can still see some spaces left when that element is not visible, shown in almosthere_report.gif
my questions:

1) can this even be done using telerik reporting?
2) how do I make the space of a hidden object on a report also go away.?

regards and thanks in advance.
Wadigzon
Top achievements
Rank 1
 answered on 22 May 2013
3 answers
290 views
I have a page that produces a number of reports by booths (for a trade show)
a few booths (10 out of 200) need a subreport to be added
I tried adding the subreport when the reports are built - the control is added but the report itself does not appear
I moved my logic to the ItemDataBound event of the report selected and nothing appears
what am I doing wrong?
Private Sub VRSummaryStore_ItemDataBound(sender As Object, e As EventArgs)
    Dim srPowerBoys As SubReport
    Dim thisReport As InstanceReportSource
    Dim myFoot As Telerik.Reporting.ReportFooterSection
    Dim X_Unit, Y_Unit As Telerik.Reporting.Drawing.Unit
    Dim APoint, UPoint As Telerik.Reporting.Drawing.PointU
    Dim subReport As Reports.VRPowerBuys
    Dim dsSubReport As DataSet
    Dim BoothNumber As Integer
 
    myFoot = Me.ReportFooterSection1
    APoint = Me.srActualTotals.Location
 
    srPowerBoys = New SubReport
    srPowerBoys.Style.BackgroundColor = System.Drawing.Color.Chartreuse
    myFoot.Items.Add(srPowerBoys)
    srPowerBoys.Left = Me.srActualTotals.Left
    srPowerBoys.Top = APoint.Y + Me.srActualTotals.Height
    srPowerBoys.Size = Me.srActualTotals.Size
    thisReport = New InstanceReportSource
    subReport = New Reports.VRPowerBoys
    thisReport.ReportDocument = subReport
    BoothNumber = Me.Report.ReportParameters(0).Value
    dsSubReport = DataManager.GetDataSP("rpt_store_powerboys_show", BoothNumber.ToString)
    subReport.DataSource = dsSubReport
End Sub
Elliott
Top achievements
Rank 2
 answered on 22 May 2013
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?