Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
350
IGDataChart Seems to be referencing the wrong version of XamDataChart
posted

I have a C# Application written in WPF in Visual Studio 2015

The application uses several WPF controls from Infragistics, cheif among which is the XAMDATACHART and associated CHARTINFOSTRIPS

SETUP

I added a reference to the following dlls, using the normal visual studio procedure:

  • InfragisticsWPF4.Controls.Charts.XamDataChart.v15.2
  • InfragisticsWPF4.Controls.Editors.XamCalendar.v15.2
  • InfragisticsWPF4.DataPresenter.v15.2
  • InfragisticsWPF4.DataVisualization.v15.2
  • InfragisticsWPF4.Documents.Core.v15.2
  • InfragisticsWPF4.Documents.Excel.v15.2
  • InfragisticsWPF4.Editors.v15.2
  • InfragisticsWPF4.v15.2

All of these dlls have a version of 15.2.20152.2038

I also added a reference to IGDataChart (version 15.2.20152.84)

The main infragistics dlls were taken from the C:\Program Files (x86)\Infragistics\2015.2\WPF\CLR4.0\Bin folder and the IGDataChart was taken from the C:\Users\Public\Documents\Infragistics\2015.2\WPF\Samples\CLR4.0\Binaries folder

Problem


On my development PC (on which I installed Infragistics) everything runs absolutely fine and works perfectly.

On a test production PC (on which Infragistics has not been installed) I get an error.

The error is "System.IO.FileLoadException: Could not load file or assembly 'InfragisticsWPF4.Controls.Charts.XamDataChart.v15.2, Version=15.2.20152.1000, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)"

The line of code at which this error occurs is "var chartStrips = new ChartInfoStripsBehavior();"


I have checked the GAC on the production machine which has no references at all to any Infragistics dll. The only dlls supplied with the application are the ones specified earlier.

I have checked and re-checked the versions of the referenced dlls, and the versions of the output dlls, and they all seem to be the most recent versions of the dlls.

I have run the Infragistics Version Update Utility, which states that all components are up to date.

I have opened the project.cs file and manually checked the versions in there

I cannot find any reference anywhere in the application or debugging info that suggests that the dll "InfragisticsWPF4.Controls.Charts.XamDataChart.v15.2" should be version 15.2.20152.1000 and not 15.2.20152.2038

This problem has only just reared its head in the last two days after two months of successful tests with the application.

Please could you advise a potential solution or point me in the right direction please?

Thanks


Steve


Parents
No Data
Reply
  • 34510
    Verified Answer
    Offline posted

    Hi Steve,

    The issue is that IGDataChart is a DLL compiled from the WPF Samples Browser solution which is built against the 15.2.20152.1000 version of the Infragistics assemblies.  Since IGDataChart was built using 15.2.1000, using this DLL in your application forces the app to try and load that specific version of the XamDataChart DLLs.  This is regardless of what version DLLs are present in your Project References.

    In order to resolve this you either need to setup a binding redirect or you need to recompile the IGDataChart project, pointing it at the 15.2.2038 version that your application is using.  Or you can rip out the classes you need from IGDataChart (if you have the source code) and add them to your project then removing IGDataChart as a reference.

Children
No Data