This project is read-only.

Error in medium trust environment

Feb 22, 2011 at 12:38 AM


I am trying to deploy my site to a shared hosting environment, which is not a full trust environment.

When I try to open a page I get this error:

System.Security.SecurityException: That assembly does not allow partially trusted callers.

I'm pretty sure this is due to the MvcPager assembly.

Any ideas on how to get around this?


Feb 22, 2011 at 1:14 AM

I downloaded the source and added the following to the AssemblyInfo.cs:


using System.Security;

using System.Security.Permissions;

[assembly: AllowPartiallyTrustedCallers()]


I recompiled and now it's working.