Telerik Forums
Reporting Forum
2 answers
374 views
Hi ,

While creating a report, for Purchase order specifically, i want the header part of the report (company particulars) from a different table, how do i link this to a data source created for the company details to the header, when trying to add fields from the DATA EXPLORER to a textbox, it is showing error that the report is linked to another data source( which is my primary data source which has the purchase order no, date etc.,)

Regards,
Jai
JaiGanesh
Top achievements
Rank 1
 answered on 22 Oct 2013
1 answer
163 views
Hi,

I have a report containing several textboxes in my header section all bound to a sqldatasource.

In of them I need to modify the value from a delimited string (item1;item2;item3 ...) to a string with newlines at each ;
item1
item2
item3

My textbox is bound to Fields.MyDataField

I have added an event handler

private void textBox4_ItemDataBinding(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.TextBox txt = (Telerik.Reporting.Processing.TextBox)sender;
    Telerik.Reporting.Processing.IDataObject dataObject = (Telerik.Reporting.Processing.IDataObject)txt.DataObject;
 
    _myDataMember = (string)dataObject["MyDataField"];
    if (_myDataMember != null)
        StringToList();
    //Here I need to rebind textbox to the modified string
 
}

In debug mode I can see all my data field values in the dataObject EXCEPT from the one I need to modify??? This one is null. BUT if I let the report render I can see the values fine.

Apart from this strange behavior, assuming the data is there, how do I rebind my textbox showing my modified string?

Thanks,
Per
Per
Top achievements
Rank 1
 answered on 22 Oct 2013
1 answer
145 views
Hi,

I've started using the new HTML5 reportviewer for MVC but unfortunately the samples and documentation seems to be pretty lacking.

How do I pass across a simple parameter to a report?  Either via a link - e.g.. a link to show an Invoice which contains the invoice id.

OR 

    Allowing user selection on a page and passing that to the report?

Stuff like this should be simple but there doesn't seem to be any documentation at all on it.
Peter
Telerik team
 answered on 22 Oct 2013
1 answer
419 views
Hello everybody,

I am losing my hair on this one. Notice, I have never used routing or MVC before, so I am probably missing something obvious. I have a classic Web Forms project and need to integrate the new HTML5 Report Viewer.

Actually, when I start the HTML5 report viewer, I get the message inside the viewer "Error registering the viewer with the service". The html page is configured as suggested in Telerik's documentation, I have created a controller named "ReportsController" (as in doc).

To make run this controller, I have added the following in the Global.asax :

protected void Application_Start(object sender, EventArgs e)
{
      WebApplication1.App_Start.WebApiConfiguration.RegisterRoutes(GlobalConfiguration.Configuration);
}

and I have created a class named "WebApiConfiguration.cs" as follows:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Http;
 
namespace WebApplication1.App_Start
{
    public static class WebApiConfiguration
    {
        public static void RegisterRoutes(HttpConfiguration httpConfiguration)
        {
            httpConfiguration.Routes.MapHttpRoute(
                name: "DefaultApi",
                routeTemplate: "api/{controller}/{id}",
                defaults: new { id = System.Web.Http.RouteParameter.Optional }
                );
 
            Telerik.Reporting.Services.WebApi.ReportsControllerConfiguration.RegisterRoutes(httpConfiguration);
        }
    }
}

Notice, I made no changes inside the webconfig.file

If I type http://localhost:65483/api/reports in the browser, I actually get some xml code :

[{"name":"PDF","localizedName":"Acrobat (PDF) file"},{"name":"CSV","localizedName":"CSV (comma delimited)"},{"name":"XLS","localizedName":"Excel 97-2003"},{"name":"XLSX","localizedName":"Excel Worksheet"},{"name":"PPTX","localizedName":"PowerPoint Presentation"},{"name":"RTF","localizedName":"Rich Text Format"},{"name":"IMAGE","localizedName":"TIFF file"},{"name":"MHTML","localizedName":"Web Archive"},{"name":"DOCX","localizedName":"Word Document"},{"name":"XPS","localizedName":"XPS Document"}]

But the HTML5 report viewer always tells : "Error registering the viewer with the service".

Really don't know what to do about this. As I said, I have no experience in routing / MVC.
Thanks a lot for your help and time,
Vlad


Milen | Product Manager @DX
Telerik team
 answered on 21 Oct 2013
3 answers
151 views
I'm wondering how to find the report format type (PDF, HTML, RTF, CSV, ...) to be able to conditionally choose the correct image (based on resolution) in my case (Something like RenderFormat global parameter in SSRS)., any idea?
Stef
Telerik team
 answered on 21 Oct 2013
1 answer
198 views
My situation in Q2 and old reportViewer:

<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
<%@ Import Namespace="System.Data" %>
 
<%@ Register Assembly="Telerik.ReportViewer.WebForms, Version=7.1.13.802, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" Namespace="Telerik.ReportViewer.WebForms" TagPrefix="telerik" %>
<%@ Register Assembly="Telerik.Reporting, Version=7.1.13.802, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" Namespace="Telerik.Reporting" TagPrefix="telerik" %>
<!DOCTYPE html>
<html>
<head id="Head1" runat="server">
    <title></title>
    <style type="text/css">  
    html#html, body#body, form#form1, div#content
    {
        height: 100%;
    }
    </style>
</head>
<body>
    <script runat="server">
        public override void VerifyRenderingInServerForm(Control control)
        {
            // to avoid the server form (<form runat="server"> requirement
        }
         
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);
            //IMPORTANT PART: setting source to instance of report passed from controller
            ReportViewer1.ReportSource = Model.Report;
        }
 
    </script>
    <form id="main" method="post" action="">
        <telerik:ReportViewer ID="ReportViewer1" Width="100%" Height="600px" runat="server">
        </telerik:ReportViewer>
    </form>
</body>
</html>

Here I can create an instance of report on server and pass it to this view to render it on client.

While I'm waiting for documentation to come out, please help me how to do this in new html5 report viewer, and what is the best/recomended practice to render reports now?

Peter
Telerik team
 answered on 21 Oct 2013
3 answers
210 views

We have created a report and are using the “Export” feature provided by the Report viewer.  All of the options are working satisfactorily except for the CSV option.  The CSV option is working as documented, but we really want to apply the “NoHeader” and “NoStaticText” options that have been documented.   The problem is that these go into the application config file.  Our report generator is part of an MMC snapin.   We do not have a configuration file to add these customizations to. All the documentation I have seen so far points to ReportProcessor.RenderReport() to programmatically modify the export behavior.  The examples around using this are not very helpful.  I do not see how to tie this into the “Export” button on the Report viewer.  I have found no events that are generated when a user chooses an export option.  I also want to use the provided UI for gathering the destination, and also use the provided “write to file” functionality.   The examples of RenderReport all seem to use a default location and provide their own write code.   

 

Is there a way to programmatically set the “NoHeader” and “NoStaticText” parameters for the CSV option without using RenderReport?   If the answer is no, can you point me to some documentation/examples of how to use RenderReport when a user selects an export option from the Export button?

 

Thanks.

Dave

Peter
Telerik team
 answered on 21 Oct 2013
2 answers
695 views
Hi,
I have a line chart which shows tempriture of a room daily. The tempriture values come from a datasource.
The X axis shows days and Y axis shows the tempriture values.

Think of that i have temriture values from dataset as below:
18.22 ,18.83 , 19.30 , 20.05 , 19.15 ,  19.25
While using the line chart by default settings, the Y axis starts from 0 and ends with some value over 21. And the steps are generated automatically. 
As seen here the min value is 18,22 and max value is 20.05 
I would like to see the line chart as below
Y axis starting from 18 and ending at 21 and steps are 0.1 
Coul you please describe how to achieve that.

I have attached a sample chart which is generated with a different tool. The chart in the screenshot describes perfectly what i want.

Thanks.
Gaurav
Top achievements
Rank 1
 answered on 20 Oct 2013
1 answer
187 views
Hello , 
haw i can  export report to be printed in Headed paper A4  ( paper with preprinted head and footer )  ? i now that i can do it by setting margins but i am searshing it in Paperkind setting .

Thank youi . 
Peter
Telerik team
 answered on 18 Oct 2013
2 answers
482 views
Hello there,
We have just downloaded recently a trial version of Telerik Reporting, its Q3 version released.
And before buying the product, our project manager asked us to make some test, essentially some "performance" tests...
Actually, I produced a report with 500 lines from database. Those lines will be grouped by two columns, and of course : the rendered table contains some agregate value (Sum).
Curiously, the RenderReport() took about 1 minute to render these 500 lines, no matter what the output format is (pdf, mhtml, xls, ...) :-(
Notice that I have put many debug breakpoints to check exactly where the performance lack resides, and thus; found that it occured when I call the RenderReport() method. In other words, the problem is not related to database access.

I tryied to remove the agregate cells, but it didn't change nothing. By the same way, I removed the grouping column, and of course, the report took about 40 seconds to be rendered, but I think it's not normal at all, cause we treated actually 500 lines, and in the future; we surely will need to produce more than 1000 lines inside one report.

Is there any known issue to avoid this performance trouble ? I just want to add eventually that the old report engine that we used was oracle-report, and we plan to go with some other third party technologies like Telerik. But with oracle-report, the same report was rendered after about 10 seconds, on the same machine, accessing the same database, with the same code architecture (asp.net mvc)

Thanks in advance
Peter
Telerik team
 answered on 18 Oct 2013
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?