I have a custom sharepoint web part that is throwing the following exception:
System.Security.SecurityException: Request for the permission of type 'Microsoft.SharePoint.Security.SharePointPermission, Microsoft.SharePoint.Security, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' failed.
at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode)
at Waverly.SharePoint.Features.WebParts.SearchesListWebPart.Render(HtmlTextWriter writer)
The action that failed was:
Demand
The type of the first permission that failed was:
Microsoft.SharePoint.Security.SharePointPermission
The Zone of the assembly that failed was:
MyComputer
My theory is that Sharepoint does not have the trust level to run the web part but I'm having difficulty figuring out how to debug this problem. Anyone have any experience debugging something like this?