Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

RDLC making call to obsolete SecurityAction Enumeration

I'm using Microsoft.Reporting.Webforms version 10 in order to parse an RDLC file and produce a PDF. The RDLC is a simple invoice with a couple of embedded expressions.

When I run the application I get an exception that a call to the obsoleted SecurityAction.RequestMinimum has been made when compiling the expressions.

Is this a known bug or something I can remedy?

An unexpected error occurred while compiling expressions. Native compiler return value: ‘[BC40000] 'RequestMinimum' is obsolete: 'Assembly level declarative security is obsolete and is no longer enforced by the CLR by default. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.'.’.

at Microsoft.Reporting.ReportCompiler.CompileReport(ICatalogItemContext context, Byte[] reportDefinition, Boolean generateExpressionHostWithRefusedPermissions, ControlSnapshot& snapshot) at Microsoft.Reporting.PreviewStore.StoredReport.EnsureCompiled(CatalogItemContextBase itemContext) at Microsoft.Reporting.PreviewStore.GetCompiledReport(CatalogItemContextBase context, Boolean rebuild, Byte[]& reportDefinition, ControlSnapshot& snapshot) at Microsoft.Reporting.PreviewStore.GetCompiledReport(CatalogItemContextBase context, Boolean rebuild, ControlSnapshot& snapshot) at Microsoft.Reporting.LocalService.GetCompiledReport(CatalogItemContextBase itemContext, Boolean rebuild, ControlSnapshot& snapshot) at Microsoft.Reporting.LocalService.CompileReport(CatalogItemContextBase itemContext, Boolean rebuild) at Microsoft.Reporting.WebForms.LocalReport.EnsureExecutionSession()

like image 932
m.edmondson Avatar asked Nov 23 '11 14:11

m.edmondson


2 Answers

I also had this issue and by me it turned out that when there is a syntax error in an expression it displayed this error.

like image 200
yoel halb Avatar answered Oct 25 '22 14:10

yoel halb


I had this issue as well when trying to run one of our reports. It turns out that the report did not build properly. Attempting to build it in Visual Studio revealed all of the errors, and after I resolved them the report ran properly. If you get this error, double check to make sure that your report actually builds.

like image 2
yourbuddypal Avatar answered Oct 25 '22 13:10

yourbuddypal