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

Error loading WPF Report Viewer Control

1 Answer 186 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Christopher Achille
Top achievements
Rank 1
Christopher Achille asked on 09 Jun 2010, 06:38 PM
  I am new to Telerik reporting, and I have just tried using it via the Trial version (Q1 2010).  I have successfully created a report and viewed it using a WinForms application, but when I try to use the WPF viewer I hit a problem.

  The problem occurs when I create a WPF Application, and then I try to drag the "ReportViewer" WPF component to a Xaml window.  I am then presented with the error:
 
"Cannot find type 'Telerik.Windows.Controls.ThemeResourceKey'. The assembly used when compiling might be different than that used when loading and the type is missing.  Error at object 'System.Windows.ResourceDictionary' in markup file 'Telerik.ReportViewer.Wpf;component/Themes/OfficeBlack/ReportViewer.xaml'."

  I have found that if I add a reference to Telerik.Windows.Controls.dll, Telerik.Windows.Controls.Input.dll, Telerik.Windows.Controls.Navigation.dll, and Telerik.Windows.Data.dll from the samples at \Program Files\Telerik\Reporting Q1 2010\Examples\CSharp\WpfDemo\bin, that everything seems to work fine.  But it is not until those references are added, which were not included as part of the Q1 2010 trial binaries, except specifically from that sample.

  Is this expected, and is it fine to include those references?  Will updates be included to those as part of the next update of reporting, or how else would one get those on an ongoing basis?

Chris Achille

1 Answer, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 10 Jun 2010, 09:18 AM
Hello Chris,

As outlined in the WPF viewer system requirements and Using Telerik Reports in WPF application help articles, those assemblies are needed in order for the WPF viewer to function properly. If you open the Visual Studio examples that we ship with the product, you would notice that references to these assemblies are present in the project (see screenshot).
In case you use Telerik RadControls for WPF version greater than 2010.1.421.35 you have to redirect all assemblies required by the Telerik WPF ReportViewer to their latest versions. To do this you need to add bindingRedirects to your app.config as shown in the Using Telerik Reports in WPF application help article and in the Introduction to the WPF Report Viewer video.

Greetings,
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
Christopher Achille
Top achievements
Rank 1
Answers by
Steve
Telerik team
Share this question
or