Ever since I upgraded my application to use the latest versions of the Telerik reporting and WPF tools I get an exception every time I try open a window in my application which uses the reportviewer.
Upgraded to 2011.3.1116.35 WPF
Upgraded to 5.3.11.1116 Reporting
XxmlParserException Occured
Could not load file or assembly 'Telerik.Windows.Controls.Navigation, Version=2011.3.1116.35, Culture=neutral, PublicKeyToken=5803cfa389c90ce7' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) Error at object 'System.Windows.Controls.ControlTemplate' in markup file 'Telerik.ReportViewer.Wpf;component/Themes/Default/ReportViewer.xaml'.
I used to Auto update feature. I also manually deleted and added the references to see if that worked. No luck.
Do you have any advice on how I can solve this?
Thanks,
Rob
11 Answers, 1 is accepted
The versions you have listed are correct i.e. the WPF report viewer in Q3 2011 is build against RadControls for WPF v.2011.3.1116.35. You say that you have used the Upgrade Wizard, but note that it only finds and updates Telerik Reporting references. The RadControls for WPF assemblies should be updated manually to the respective version. As per the Deploying WPF Applications help article, the required assemblies are:
- Telerik.Reporting.dll
- Telerik.ReportViewer.Wpf.dll
- Telerik.Reporting.XpsRendering.dll
- Telerik.Windows.Data.dll
- Telerik.Windows.Controls.dll
- Telerik.Windows.Controls.Input.dll
- Telerik.Windows.Controls.Navigation.dll
Regards,
Steve
the Telerik team
The following items were and are up to date using WPF v2011.3.1220.35 within my application.
- Telerik.Windows.Data.dll
- Telerik.Windows.Controls.dll
- Telerik.Windows.Control.Input.dll
- Telerik.Windows.Controls.Navigation.dll
When I did the auto update / convert I updated both reporting and wpf.
Could not load file or assembly 'Telerik.Windows.Controls.Navigation, Version=2011.3.1116.35
I'm using the latest version of WPF references 2011.3.1220.35 and for reporting I'm using 5.3.12.119.
Why would it be asking for 2011.3.1116.35?
Rob
Let me run over my problems again.
My application compiles with no errors and runs well until I try to open a new window at runtime which contains the WPF ReportViewer.
As soon as the report viewer window opens at runtime I get the following error:
XamlParseException
Could not load file or assembly 'Telerik.Windows.Controls.Navigation, Version=2011.3.1116.35, Culture=neutral, PublicKeyToken=5803cfa389c90ce7' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) Error at object 'System.Windows.Controls.ControlTemplate' in markup file 'Telerik.ReportViewer.Wpf;component/Themes/Default/ReportViewer.xaml'.
Notice it's trying to look for version 2011.3.1116.35.
Within Visual Studio 2010 I can view the designer window of the ReportView with no problems.
These are my references:
Reporting (Q3 2011 SP1):
- Telerik.Reporting - 5.3.12.119
- Telerik.Reporting.OpenXmlRendering - 5.3.12.119
- Telerik.Reporting.XpsRendering - 5.3.12.119
- Telerik.ReportViewer.Wpf - 5.3.12.119
- (non telerik) DocumentFormat.OpenXml - 2.0.5022.0
WPF:
- Telerik.Windows.Controls - 2011.3.1220.35
- Telerik.Windows.Controls.Data - 2011.3.1220.35
- Telerik.Windows.Controls.Input - 2011.3.1220.35
- Telerik.Windows.Controls.Navigation - 2011.3.1220.35
- Telerik.Windows.Data - 2011.3.1220.35
- Telerik.Windows.Documents - 2011.3.1220.35
I really don't understand what the problem is.
I downloaded just the DLLs from the Telerik website for WPF Version 2011.3.1116.35.
I replaced all v2011.3.1220.35 DLLs with v2011.3.1116.35 DLLs in my project references and it now works fine.
Any ideas why I couldn't use the latest WPF DLLs with the Latest version of WPF ReportViewer?
Thanks for your time.
**** EDIT ****
I went into VS2010 editor and the WPF page which has the report viewer now throws an exception at design time.
Error 1 Could not load file or assembly 'Telerik.Windows.Controls, Version=2011.3.1116.35, Culture=neutral, PublicKeyToken=5803cfa389c90ce7' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) E:\Software\VB Code\Stately Production System\ProductionControlWPF-2\PrintUnit.xaml 1 1 ProductionControlWPF-2
It's funny. It either works at design time and not at runtime. Or swapping the DLLs cause it to fail at design time and work at run time.
In v. 5.3.12.119 we have not built against the latest WPF controls version, so if you have referenced RadControls for WPF Q3 SP1 (2011.3.1220), you should add binding redirects in order for the viewer to function correctly. For more information refer to How to: Add report viewer to a WPF application Binding Redirects section. If the problem persists, please open a support ticket and attach a sample project that exhibits the problem so we can look into it locally.
Regards,
Steve
the Telerik team
How long do I have to maintain the version numbers in the app.config as I have never had to do this before.
Regards
Craig
<
runtime
>
<
assemblyBinding
xmlns
=
"urn:schemas-microsoft-com:asm.v1"
>
<
dependentAssembly
>
<
assemblyIdentity
name
=
"Telerik.Windows.Controls"
culture
=
"neutral"
publicKeyToken
=
"5803cfa389c90ce7"
/>
<
bindingRedirect
oldVersion
=
"0.0.0.0-65535.65535.65535.65535"
newVersion
=
"2011.3.1220.35"
/>
</
dependentAssembly
>
<
dependentAssembly
>
<
assemblyIdentity
name
=
"Telerik.Windows.Controls.Input"
culture
=
"neutral"
publicKeyToken
=
"5803cfa389c90ce7"
/>
<
bindingRedirect
oldVersion
=
"0.0.0.0-65535.65535.65535.65535"
newVersion
=
"2011.3.1220.35"
/>
</
dependentAssembly
>
<
dependentAssembly
>
<
assemblyIdentity
name
=
"Telerik.Windows.Controls.Navigation"
culture
=
"neutral"
publicKeyToken
=
"5803cfa389c90ce7"
/>
<
bindingRedirect
oldVersion
=
"0.0.0.0-65535.65535.65535.65535"
newVersion
=
"2011.3.1220.35"
/>
</
dependentAssembly
>
</
assemblyBinding
>
</
runtime
>
It depends on whether you would be updating to the new releases of Telerik Reporting and RadControls for WPF. In the Q1 2012 version of Telerik Reporting, we would build against the Q1 2012 of RadControls, so if you upgrade both, you won't need the bindingRedirect.
All the best,
Steve
the Telerik team