I'm using .Net 4.5 and ReportViewer 11 in local mode. My reports are rendered very slowly (10 min). I found in this post that adding <trust legacyCasModel="true" level="Full"/>
to web.config will solve the problem, and it did. Report render time went from 10 minutes to 10 seconds, but now my dynamic variables in other parts of the system don't work. This is the error:
Dynamic operations can only be performed in homogenous AppDomain.
Is there a way to set <trust legacyCasModel="true" level="Full"/>
or something with the same effect in only one page?
Please use following link for more information
https://codeontime.com/blog/2014/08/improving-performance-of-reports-in
Add:
<trust legacyCasModel="true" level="Full"/>
in Section: configuration/system.web of Webconfig. It helps to Improve report Performance by 10 Times. But effects dynamic objects in MVC projects.
Changing the .net framework to 3.5 will help you load your reports in half a time. You can give a try in your case.
The latest in this issue can be found here https://connect.microsoft.com/VisualStudio/feedback/details/561679/reporting-services-using-parameter-for-dynamic-grouping-very-slow and it looks like it may be addressed in sql server 2012.
If you are not using 4.5 specific features rollback to 3.5 is the most feasible option. Since the cas setting is part of the web.config the option is not available on a per page basis
Consider building a one page sub site for your report page where the sub site is a separate application with a 3.5 app pool, might be worth a quick test
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With