Telerik Forums
Reporting Forum
3 answers
536 views

Can someone provide a demo with using the asp.net Webform viewer?  I realize this is a legacy control but I wanted to try this one first before tackling the HTML 5 viewer.

 

I have created a simple Crosstab report with nothing but a crosstab object and a textbox title.  I have assigned the report to a ObjectDataSource to a custom business data entity class with public properties although I did not use any of the fields.  I just want to be able to load this report with the header text using that viewer.

Below is the HTML and code behind for the report viewer:

<form id="form1" runat="server">
  
        <telerik:ReportViewer ID="ReportViewer1" runat="server">
            
        </telerik:ReportViewer>
  
    </form>

protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                var typeReportSource = new Telerik.Reporting.TypeReportSource();
                typeReportSource.TypeName = "QuiCx.Web.Pages.Demos.KendoReporting.CrossTab";
                this.ReportViewer1.ReportSource = typeReportSource;
            }
        }

 

When I run the report viewer I get this error:

Invalid report type
Value cannot be null.
Parameter name: type
at Telerik.Reporting.Processing.TypeReportDocumentResolver.Resolve(IProcessingContext context, TypeReportSource rs)
at Telerik.Reporting.Processing.ReportDocumentResolver`1.Telerik.Reporting.Processing.IReportDocumentResolver.Resolve(IProcessingContext context, ReportSource rs, Boolean loadParameters)
at Telerik.Reporting.Processing.ReportDocumentResolver.<>c__DisplayClass1.<Resolve>b__0(IReportDocumentResolver r)
at Telerik.Reporting.Processing.ReportDocumentResolver.Bind[T](IProcessingContext context, ReportSource source, Func`2 func)
at Telerik.Reporting.Processing.ReportDocumentResolver.Resolve(IProcessingContext context, ReportSource source, Boolean loadParameters)
at Telerik.ReportViewer.WebForms.ParametersPage.ResolveReportDocument(ReportSource reportSource)
at Telerik.ReportViewer.WebForms.ParametersPage.get_ReportDocument()
at Telerik.ReportViewer.WebForms.ParametersPage.get_ParamsManager()
at Telerik.ReportViewer.WebForms.ParametersPage.CreateChildControls()
at System.Web.UI.Control.EnsureChildControls()
at Telerik.ReportViewer.WebForms.ParametersPage.OnPreLoad(EventArgs e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

 

 

 

Can someone point me in the right direction?  The demos provided does not use this report viewer.  All of them use the HTML 5 viewer.

 

Stef
Telerik team
 answered on 28 Jul 2016
7 answers
462 views
I have a problem with the Report Viewer. I installed Reporting Q3 2010 and the project I imported Telerik.ReportViewer.WinForms, but in my toolbox is not displayed is the component (http://imageshack.us/photo/my-images/560/telerikreport.jpg/).

What should I do to my Report Viewer appears, as shown at this link: http://www.telerik.com/help/reporting/winforms-report-viewer-embedding.html

Thanks for your help:)
Stef
Telerik team
 answered on 28 Jul 2016
1 answer
722 views

Hi everybody.

recently I was working in a project where the requirement was save "trdx" files into a DB and show them in a asp.net web form application. As additional information, the data to populate the reports were in XML files.

so I realized to late that "Telerik reporting" doesn't accept xml as datasource or at least I couldn't find a direct way to achieve that. I read that you can transform the xml into objectdatasource but it was little complicated due the dynamism in the project.

at the end I decided to work with a user function that basically accept two parameters 

- XPathExpression => the xpath query to find the data in the xml string

- xmlDocument  => the xml string, I pass it to my report by a parameter.

The function :   

[Function(Category = "XPath", Namespace = "XmlTelerikReporting", Description = "Find the information from the default report parameter XmlDataSource using XPath expressions ")]
  public static object XmlValue(string XPathExpression, string xmlDocument)
  {
 
      #region XmlValue
      try
      {
          XmlDocument xmlDoc = new XmlDocument();
          xmlDoc.LoadXml(xmlDocument);
          xmlDoc.DocumentElement.RemoveAttribute("xmlns");
          XmlDocument newDom = new XmlDocument();
          newDom.LoadXml(System.Text.RegularExpressions.Regex.Replace(
                  xmlDoc.OuterXml
                  , @"(xmlns:?[^=]*=[""][^""]*[""])",
                  "",
                  System.Text.RegularExpressions.RegexOptions.IgnoreCase | System.Text.RegularExpressions.RegexOptions.Multiline));
 
 
          object xmlXPathValue = newDom.SelectSingleNode(XPathExpression) != null ? newDom.SelectSingleNode(XPathExpression).Value : null;
 
          return xmlXPathValue;
 
      }
      catch (Exception ex)
      {
          //a pretty ans secret way to catch exceptions
      }
      #endregion       
  }

 

How to use in expression:

 = XmlTelerikReporting.XmlValue(   "//@parametertofind" , Parameters.xmlDocument.Value   )

I will really  appreciate any feedback regarding to my code display above.

and it will be awesome if you implement something in telerik reporting in order to accept XML files as Datasource

Regards!

 

  

 

Stef
Telerik team
 answered on 27 Jul 2016
1 answer
212 views

Hi,

I have a Asp.Net MVC web application. Using Telerik html report viewer. I am using Visualstudio 2015 to open the solution. When I open ReportDesigner file, see Telerik report controls like , table, crossbar, list are missing in VS toolbox.

 I tried exporting controls from Telerik.Reporting dll in toolbox but no luck.

Do I have to install any plugin to get all these controls listed in the toolbox of VS 2015?

 

Stef
Telerik team
 answered on 27 Jul 2016
1 answer
331 views

Hi, is there a way to retreive the old and good query designer like the one in visual studio? Honestly, the fact that we can type the query while in the designer or, lost what we put outside of it, is a pain in the ass and is not usefull at all. The one in Visual Studio is perfect. Why it is gone?

thanks,

Stef
Telerik team
 answered on 26 Jul 2016
3 answers
111 views
Hello,
 
Is support for the displaying of reports available in the MVC .Net Core 1.0 release yet?

 

Thanks you,

Scott

Stef
Telerik team
 answered on 26 Jul 2016
3 answers
494 views
I have a report with multiple tables. One of the tables has a dynamic number of rows and columns. Both the number of columns and the number of rows makes the table larger than one page (spanning it over 4 pages). But something is adding blank pages to the report, sort of like the other tables are wide enough to require 2 pages (but they are not that wide).

If I delete the table, the other tables render correctly. Or, if I set the paper size to 17x11 inches (big enough to hold the table on one page), I don’t get extra tables. I've set Keep Together = False on all elements of the table, panel, and section.

I attached .png's of each page. I had to block the content, but I hope it's still useful. As you can see, pages 2, 4, 6, and 8 have the page number in the footer, but are otherwise blank. They shouldn't be in the report.
Stef
Telerik team
 answered on 26 Jul 2016
2 answers
226 views

How to add  the graph in table cell ?? ..( like Tablelayout panel )

i want to add a more than 10  graph programmatically in row and column manner.so tried to add the graph into table cell , but it not accept the graph control.

please give any idea .....

Katia
Telerik team
 answered on 26 Jul 2016
5 answers
749 views

I am very green with reporting in general.

I am using VS2013 to design a simple report.

- I created a report and a data source.

- I added a report parameter and a data source to show a list of available values.

 

My question:

1) How do I take the report parameter and tie it to my data source?

 

For example the data source is simple "SELECT * FROM BOOKS"

I would like to set up as "SELECT * FROM BOOKS WHERE BOOK_TYPE  = [MY PARAMETER]"

I manually added the following to my SelectCommand for the data source

SELECT * FROM BOOKS WHERE BOOK_TYPE  == Parameters.ReportCodeParam.Value

However that didn't work.

On the data source I also see a Parameters property.  When I go to that property I don't see the parameter that I created on the report.

 

Please advise.

 

Katia
Telerik team
 answered on 25 Jul 2016
9 answers
1.4K+ views
Hi,

Is there a way to set the value of a multivalue parameter in the data source wizard for debugging purposes?  The design time property value I mean.

Thanks,
Darren
Stef
Telerik team
 answered on 25 Jul 2016
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?