Monday, 2 September 2013

Server Error in '/' Application. System.Security.SecurityException: That assembly does not allow partially trusted callers

Server Error in '/' Application. System.Security.SecurityException: That
assembly does not allow partially trusted callers

I am getting this error on some pages when deployed on server.
Live Page Link
I am not sure how to fix this error. I have read some of the posts on
StackOverflow & asp.net forums websites.
In my cs file
using System;
using System.Collections.Generic;
using System.Web.UI.WebControls;
using System.Web.UI;
using System.Web.Security;
using com.paypal.sdk.services;
using com.paypal.sdk.profiles;
using com.paypal.sdk.util;
using System.Configuration;
using System.Web;
using System.Linq;
Stack Trace
[SecurityException: That assembly does not allow partially trusted callers.]
GlaziersCenter.cart.Page_Load(Object sender, EventArgs e) +0
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o,
Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender,
EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +91
System.Web.UI.Control.LoadRecursive() +74
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+8431
System.Web.UI.Page.ProcessRequest(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+253
System.Web.UI.Page.ProcessRequest() +78
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
System.Web.UI.Page.ProcessRequest(HttpContext context) +49
ASP.cart_aspx.ProcessRequest(HttpContext context) in
App_Web_sa5qpq1w.5.cs:0
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
+100
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean&
completedSynchronously) +75

No comments:

Post a Comment