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

Exception when generating a report

3 Answers 477 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Patrick
Top achievements
Rank 2
Iron
Iron
Iron
Patrick asked on 12 Sep 2018, 03:11 PM

Hello,

I've just updated to Reporting R3 2018 and I now have an exception when generating a PDF from a report, when a ReportProcessor instance is created. The exception message is the following:

[A]Telerik.Reporting.Configuration.ReportingConfigurationSection cannot be cast to [B]Telerik.Reporting.Configuration.ReportingConfigurationSection. Type A originates from 'Telerik.Reporting, Version=12.1.18.620, Culture=neutral, PublicKeyToken=a9d7983dfcc261be' in the context 'Default' at location 'C:\Temp\Temporary ASP.NET Files\vs\293ea1ac\b0f39161\assembly\dl3\a336f798\0099b611_b108d401\Telerik.Reporting.dll'. Type B originates from 'Telerik.Reporting, Version=12.2.18.912, Culture=neutral, PublicKeyToken=a9d7983dfcc261be' in the context 'Default' at location 'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\Telerik.Reporting\v4.0_12.2.18.912__a9d7983dfcc261be\Telerik.Reporting.dll'.

Unfortunately, the release notes doesn't say anything about a change on this.

Can you please explain what needs to be done to make it work again?

3 Answers, 1 is accepted

Sort by
0
Patrick
Top achievements
Rank 2
Iron
Iron
Iron
answered on 12 Sep 2018, 03:18 PM

I've found something in the web.config with:

<configSections>
  <section name="Telerik.Reporting"
           type="Telerik.Reporting.Configuration.ReportingConfigurationSection, Telerik.Reporting"
           allowLocation="true"
           allowDefinition="Everywhere" />
</configSections>

 

This is almost the same as the example in the documentation (removed the Version, Culture and PublicKeyToken)

0
Accepted
Silviya
Telerik team
answered on 17 Sep 2018, 06:01 AM
Hello Patrick,

This error seems to be thrown by the fact that you have old references (v 12.1.18.620) in your project's bin folder. Test cleaning the project (deleting the bin folder) and build it once again. Check if the newest version is referred.

In case the issue still persist, open new support ticket and send us the problematic project for local investigation.

Regards,
Silviya
Progress Telerik
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 Feedback Portal and vote to affect the priority of the items
0
Patrick
Top achievements
Rank 2
Iron
Iron
Iron
answered on 27 Sep 2018, 04:54 AM

Hi Silviya,

You're right: there was old references that wasn't updated automatically.

I've corrected this and it's OK now.

Thanks for your help

Tags
General Discussions
Asked by
Patrick
Top achievements
Rank 2
Iron
Iron
Iron
Answers by
Patrick
Top achievements
Rank 2
Iron
Iron
Iron
Silviya
Telerik team
Share this question
or