Telerik Forums
Reporting Forum
6 answers
917 views
Just today I tried opening up a report to make edits, and I get the titular error in Visual Studio: "Error HRESULT E_FAIL has been returned from a call to a COM component"

I've attached a screenshot.

After I got this error, I upgraded to the latest release. Note that I can still view reports in my MVC application, but I can't edit them with Visual Studio.

What has gone wrong, and how do I correct it?

Thanks,

Matt
Stef
Telerik team
 answered on 05 Feb 2014
3 answers
125 views
I have to say, I really like what I see with Telerik Reporting.  The accuracy of the export to Excel and PDF is what has led me to look at it deeper and deeper.  However the Chart Object in the reports simply sucks.  When I was using the RadChart in a standard ASP.NET page I could easily get in and change individual bar colors during the ItemDatabound event.

The attached image is a chart I created using RadChart and a standard ASP.NET webform.  If the value in the PeakUsages series (Bar) exceeds the value in the LicenseCount series (line) then the color of the chart bar is changed to red.  This is accomplished with the simple code listed below.

However the chart in reporting (which as I understand it is suppose to be RadChart under the covers) can't do this,  It doesn't appear that you can modify the chart during the databound event.  Why?   

To make matters worse, attempting to refine the charts visual appearance in Visual Studio is painful at best.  You have to drill into 15 different properties to change the back ground color of the plot area.  Then when you use preview to see how it looks and then switch back to design mode.  Your previous properties context is completely lost.  When you return to design mode your selection is set back to the report not the previous selected object and you lose all of the expansion you had done in the properties pane.  (Note I am using VS2010 RC with Q1 2010).

The shear fact that I can't duplicate the chart functionality in Telerik Reporing is forcing me to continue to use RadGrid and RadCharts as my reporting solution, which really sucks as I have to spend a lot more time focusing on code to properly export the Grid to Excel and PDF.

When is the Chart in Telerik reporting going to become a first class object?   
Things I'd like to see include
  1. Full control over the chart rendering from the code behind.  Allow me to have the same ItemDataBound event logic as RadChart
  2. Context, Context, Context.   Remember where I was when I return from preview, don't force me to reselect the chart, expand properties etc.
  3. Cut and paste a chart definition, or access to the markup for the chart.  
  • I want to be able to paste a chart definition from an asp.net page into a report.  Or allow me to mark it up in the same manor, which would allow me to quickly duplicate the look and feel and refine it without having to mess with the properties pane.

protected void rowChart_ItemDataBound(object sender, Telerik.Charting.ChartItemDataBoundEventArgs e) 
    { 
    if(e.SeriesItem.Parent.Name == "PeakUsages"
        { 
        DataRowView drv = (DataRowView)e.DataItem; 
        if(drv["PeakUsages"] != DBNull.Value) 
            { 
            if(Convert.ToInt16(drv["PeakUsages"]) > Convert.ToInt16(drv["LicenseCount"])) 
                { 
                e.SeriesItem.ActiveRegion.Tooltip = string.Format("Usage exceeds license: \nDate: {0}\nUsage: {1} \nLicense: {2}"
                                                                   Convert.ToDateTime(drv["UsageDate"]).ToShortDateString(),  
                                                                   drv["PeakUsages"].ToString(),  
                                                                   drv["LicenseCount"].ToString()); 
                e.SeriesItem.Label.Visible = false
                e.SeriesItem.PointAppearance.FillStyle.MainColor = Color.DarkRed; 
                e.SeriesItem.Appearance.FillStyle.MainColor = Color.DarkRed; 
                e.SeriesItem.Appearance.FillStyle.SecondColor = Color.Red; 
                e.SeriesItem.PointAppearance.FillStyle.SecondColor = Color.DarkRed; 
                e.SeriesItem.PointAppearance.Border.Color = Color.DarkRed; 
                } 
            else 
                { 
                e.SeriesItem.Label.Visible = false
                e.SeriesItem.PointAppearance.Visible = false
                e.SeriesItem.ActiveRegion.Tooltip = string.Format("Date: {0} \nUsages: {1}", Convert.ToDateTime(drv["UsageDate"]).ToShortDateString(), drv["PeakUsages"].ToString()); 
                } 
            } 
        else 
            { 
            e.SeriesItem.Visible = false
            e.SeriesItem.Label.Visible = false
            e.SeriesItem.PointAppearance.Visible = false
            } 
        } 
    else 
        e.SeriesItem.Label.Visible = false
    } 

Stef
Telerik team
 answered on 05 Feb 2014
34 answers
2.9K+ views
I've spent a considerable amount of time searching the documentation for an example and reading through other posts, but haven't found what I'm looking for, so forgive me if this is covered somewhere already, I just haven't seen it.

Basically, I'd like to create a report with a dynamic table on the report. By dynamic I mean at design time I don't necessarily know all of the fields that will be part of the dataset (the dataset is built at runtime based upon input from the user). Ideally, I would like to take my populated dataset and bind it to the report at runtime, and add, if necessary, any columns to the Telerik Reports table on the report. 

Are there any examples or demos of such a report? Is this even possible?
Hinata
Top achievements
Rank 1
 answered on 05 Feb 2014
2 answers
587 views

I'm trying to implement my first ReportViewer, and I'm getting this error:

Server Error in '/' Application.
--------------------------------------------------------------------------------
  
The http handler needed by the Report Viewer has not been registered in the application's web.config file.  Add <add verb="*" path="Telerik.ReportViewer.axd" type = "Telerik.ReportViewer.WebForms.HttpHandler, Telerik.ReportViewer.WebForms, Version=4.2.10.1221, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" /> to the system.web/httpHandlers section of the configuration file. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 
  
Exception Details: Telerik.ReportViewer.WebForms.ReportViewerHandlerNotRegisteredException: The http handler needed by the Report Viewer has not been registered in the application's web.config file.  Add <add verb="*" path="Telerik.ReportViewer.axd" type = "Telerik.ReportViewer.WebForms.HttpHandler, Telerik.ReportViewer.WebForms, Version=4.2.10.1221, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" /> to the system.web/httpHandlers section of the configuration file.
  
Source Error: 
  
The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:
  
1. Add a "Debug=true" directive at the top of the file that generated the error. Example:
  
  <%@ Page Language="C#" Debug="true" %>
  
or:
  
2) Add the following section to the configuration file of your application:
  
<configuration>
   <system.web>
       <compilation debug="true"/>
   </system.web>
</configuration>
  
Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.
  
Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.  
  
Stack Trace: 
  
  
[ReportViewerHandlerNotRegisteredException: The http handler needed by the Report Viewer has not been registered in the application's web.config file.  Add <add verb="*" path="Telerik.ReportViewer.axd" type = "Telerik.ReportViewer.WebForms.HttpHandler, Telerik.ReportViewer.WebForms, Version=4.2.10.1221, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" /> to the system.web/httpHandlers section of the configuration file.]
   Telerik.ReportViewer.WebForms.ReportViewer.CheckHttpHandlerRegistrations() +207
   Telerik.ReportViewer.WebForms.ReportViewer.OnInit(EventArgs e) +62
   System.Web.UI.Control.InitRecursive(Control namingContainer) +333
   System.Web.UI.Control.InitRecursive(Control namingContainer) +210
   System.Web.UI.Control.InitRecursive(Control namingContainer) +210
   System.Web.UI.Control.InitRecursive(Control namingContainer) +210
   System.Web.UI.Control.InitRecursive(Control namingContainer) +210
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6741
   System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +242
   System.Web.UI.Page.ProcessRequest() +80
   System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
   System.Web.UI.Page.ProcessRequest(HttpContext context) +49
   ASP.myplannerreport_aspx.ProcessRequest(HttpContext context) +37
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75
  
   
  
  
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3615; ASP.NET Version:2.0.50727.3618

But I have this in my Web.Config:
<system.webServer>
        <handlers>
        <remove name="Telerik_Web_UI_SpellCheckHandler_axd" />
        <add name="Telerik_Web_UI_SpellCheckHandler_axd" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
        <remove name="Telerik_Web_UI_DialogHandler_aspx" />
        <add name="Telerik_Web_UI_DialogHandler_aspx" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
        <remove name="Telerik_RadUploadProgressHandler_ashx" />
        <add name="Telerik_RadUploadProgressHandler_ashx" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
        <remove name="Telerik_Web_UI_WebResource_axd" />
        <add name="Telerik_Web_UI_WebResource_axd" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" preCondition="integratedMode,runtimeVersionv2.0" />
        <remove name="Telerik_ReportViewer_axd"/>
        <remove name="Telerik.ReportViewer.axd_"/>
        <add name="Telerik.ReportViewer.axd_*"
                 path="Telerik.ReportViewer.axd"
                 verb="*"
                 type="Telerik.ReportViewer.WebForms.HttpHandler, Telerik.ReportViewer.WebForms, Version=4.2.10.1221, Culture=neutral, PublicKeyToken=a9d7983dfcc261be"
                 preCondition="integratedMode,runtimeVersionv2.0" />
    </handlers>

Any ideas?
Rakesh
Top achievements
Rank 1
 answered on 05 Feb 2014
4 answers
208 views
I am using a chart within a telerik report. I've gotten it mostly under control, however one issue remains. 

the X axis could have 10, or 500 items. Is there any way to limit how many data points are labeled?   By default, telerik displays every one, and it's just one big gray blob.. 

is there a way to just tell telerik to show 5 labels across x-axis ? this could be every other item, or every 1000th item. whatever is necessary to make it look nice and spaced. Do i have to perform calculus in my sql select to figure this out and set labels that way?  because that seems to be the only way out of this mess..  this has to be a common problem. 
Stef
Telerik team
 answered on 04 Feb 2014
1 answer
73 views
Hello,
I need to know which version if telerik reporting viewer is build on WPF 2013.2.724.40

I need it since with 2013 I've got WPF visualization problem with a radgrid and need to hotfix downgrading to 724 but with 724 I have reference problem when using 7.2.14.127

Thanks
Stef
Telerik team
 answered on 04 Feb 2014
1 answer
231 views
Hi,

I am using out proc session state in our application and have done all necessary changes mentioned in Design Considerations for Out-proc Session State.
But while populating reports, ItemDataBinding and ItemDataBound never get called even after these changes.
Is there anything I missed out or need to add?
KS
Top achievements
Rank 1
 answered on 03 Feb 2014
1 answer
94 views
Hi!

I have 2 Questions for which I haven´t found a sufficent answer elsewhere.

I´m using Telerik Reporting Q2 / 2012 for a Silverlight 4 project, so upgrading is not an option. (Or do the newer Report Versions still work with SL 4?)
The datasource I use is an object datasource.

1. The Datasource contains arrays and lists. In my Report I want to have a dynamic part for each item in the List. I Understand, that you can´t access elements of the list directly, but have to use a seperate datasource for the array. I tried that but the only datafield I see in there ist one item.
How can I implement a report with a dynamic part (f.e. a row in a table) that repeats for every element in the array, without having the need to design them all myself?

2. Trying to solve 1. I have made a binding to the visibility of a row to the number of elements in the array. The row wasn´t visible if the count was less than a specific number, but there was still a white space for it reserved in the report. How can I not only make a part of the report invisible, but also prevent that there is some space reserved for it?

Kind regards
KS
Top achievements
Rank 1
 answered on 31 Jan 2014
1 answer
65 views
I am working with 2013 Q3 reporting and VS2013 when I design a drill down report the expand/collapse does not work in preview, but works fine when published to the intranet.
Nasko
Telerik team
 answered on 31 Jan 2014
1 answer
110 views
Is it possible to use a 'Filtered' Telerik Grid as a datasource for a report.?
I have a grid that has numerous columns that can be filtered on. Once a use is done applying their filters, I want to pass the results to a report. Not just export the grid. I can design the Report using the same sproc that the grid uses so in theory I would be applying the filter inside the sproc and the report would be none the wiser, all the columns would be the same. So if I design the report initially using a SQLDataSource can I swap it out at run time with the results of the filtered grid?It would not be feasible to create report parameters for all the fields that can be filtered in the grid, I just want to leverage what the grid can already do.
Nasko
Telerik team
 answered on 31 Jan 2014
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?