Error in ReportViewer after deploy ClickOnce - HRESULT: 0x80131401

1

I hope that will help me with this issue.

I have a problem with a application (winforms) build with .net framework 4.5 and ReportViewer 11 (Reporv Viewer 2012). Ago few weeks I deploy using Windows Azure and install to clients, but when i run a report show me an exception.

**An error occurred during local report processing.
Failed to load expression host assembly. Details: Loading this assembly would produce a different grant set from other instances. (Exception from HRESULT: 0x80131401)**

When I deploy in network (LAN) was working fine, but when I deploy via internet i get this error, this error only occurs when i start the application via shortcut .appref-ms, but if I start application executing .exe file show report correctly.

Some else have this problem and how solve?

Thanks.

c#
winforms
.net-4.5
clickonce
reportviewer
asked on Stack Overflow Jun 6, 2014 by ByAlaN • edited Jun 7, 2014 by Systematix Infotech

1 Answer

0

I found my problem.

I solve this only comment this line, because i dont use ngen ;). i just comment attribute [LoaderOptimization(LoaderOptimization.MultiDomainHost)] in Main method. This works fine for me, check if you have and comment ;).

answered on Stack Overflow Jun 20, 2014 by ByAlaN

User contributions licensed under CC BY-SA 3.0