This is a migrated thread and some comments may be shown as answers.

Problem loading report viewer - could not load type ...OpenXmlRendering

1 Answer 261 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Pamela
Top achievements
Rank 1
Pamela asked on 16 Apr 2011, 06:59 PM
Hello
I am working in WPF and have attempted to build a "hello world" report.  i created a simple report using the wizard - no problem.  Then i added a reportviewer to the main xaml page and gave it the name "viewer". 

The xaml is as follows:

 

 

 

<tr:ReportViewer Name="viewer"/>

 



The namepaces that the control added to the page were:

xmlns

 

 

:telerik="http://schemas.telerik.com/2008/xaml/presentation"

 

 

 

 

xmlns:tr="http://schemas.telerik.com/wpf" x:Class="WpfApplication2.MainWindow"

 

 

 

xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

 

 

 

xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

I am getting the error:

 


Could not load type 'Telerik.Reporting.OpenXmlRendering.Presentation.PresentationReport' from assembly
'Telerik.Reporting, Version=5.0.11.316, Culture=neutral, PublicKeyToken=a9d7983dfcc261be'.

References added are:

Telerik.Reporting
Telerik.Reporting.OpenXmlRendering
Telerik.Reporting.Service
Telerik.ReportViewer.Wpf
Telerik.Windows.Controls
Telerik.Windows.Controls.Input
Telerik.WIndows.Controls.Navigation
Telerik.WIndows.Data

Target Framework is .Net Framework 4 (not client)
I am working with Reporting Q1 2011 and RadControls for WPF Q1 2011

The page will not load with the report viewer on it.  It crashes in the InitializeComponent() call of the page.

Of course, the page runs fine if i remove the reportviewer control.

When i search the class view for Presentation.PresentationReport there are no hits, so this file is not anywhere in the references.  What am i missing?

any ideas please?  I always do a very simple test application before moving forward.  I would really like to have this tool work, so i can avoid going back to SSRS for reporitng.

Pam



1 Answer, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 18 Apr 2011, 06:00 PM
Hello Pamela,

The error you've encountered can only occur if you are missing required references. A little more background:

For compatibility reasons Telerik Reporting is build against .Net 2.0 but the OpenXml rendering requires .Net 3.5 or above (see Open XML SDK 2.0 for Microsoft Office and Deploying WPF Applications). This is why we have separated the OpenXml rendering from the Telerik.Reporting assembly. However we do have plans once .Net 3.5 is  largely accepted to migrate to .Net 3.5. Once we migrate Telerik.Reporting to .Net 3.5 we will merge the Telerik.Reporting.OpenXmlRendering and Telerik.Reporting assemblies in order to ease our customer from adding additional assembly. This is why we are trying to load the Telerik.Reporting.OpenXmlRendering.Presentation.PresentationReport type from the Telerik.Reporting and an exception is thrown that we handle internally. This is all preparation for the future migration to a greater version of .Net. Because we handle that exception we presume that you have enabled the First Chance Exceptions from the Debug menu, select Exceptions (or use Ctrl+D,E from the keyboard). If this is the case you don't have to worry about that exception because we do handle it and your clients will not be affected.

If this is not the case and you need additional assistance we will appreciate if elaborate further where you have seen the exception (Output, Event Viewer etc.) and prepare a sample project that exhibits the issue. Generally we don't need your whole project and a runnable example to debug we will be enough.

All the best,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
Pamela
Top achievements
Rank 1
Answers by
Steve
Telerik team
Share this question
or