Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

webpart deployment - custom policy file

  Asked By: Bob    Date: Apr 21    Category: Sharepoint    Views: 1010

I am trying to deploy custom web part using custom policy file. For
this I created a new policy file same as wss_medium security, and added
codegroup for my web part. I derived the PublicKeyBlob using secutil.exe

When I try to drag and place my custom web part on portal page, it
shows me error stating
A Web Part or Web Form Control on this Web Part Page cannot be
displayed or imported because it is not registered on this site as safe.

In my event log it logs an error stating
Failure in loading assembly: webpart, Version=, Culture=neutral,

The web part works fine if I place the dll in GAC. In the web part is
accessing an web service which is not hosted on my system.
The IPermission block for it looks like this
<URI uri="$OriginHost$"/>

What is that am doing wrong?



2 Answers Found

Answer #1    Answered By: Shayla Mcbride     Answered On: Apr 21

There must be something in your code which is throwing "security exception".
That's the only reason it s not working from the bin and running from the GAC.

Answer #2    Answered By: Jarvis Rowe     Answered On: Apr 21

Error i get on my portal  page is "Execution permission cannot be

Didn't find what you were looking for? Find more on webpart deployment - custom policy file Or get search suggestion and latest updates.