Help with security policy

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



I was working on a VSTO 2003 Excel project, and everything was going fine.
Had to reinstall Windows on Monday, thus wiping out the Security Policy that
I had set up. I tried recreating the Security Policy manually (using the
..NET Configuration tool), but now my project won't run, giving the error:

"The assembly MyProject could not by found at .\MyProject_bin\ or could not
be loaded. You can still edit and save the document..."

I've changed nothing in my project (I just opened it in VS.NET and clicked
Run). I'm pretty sure that the problem doesn't lie with the MyProject
assembly (or the Excel file), rather with one of the referenced assemblies,
of which there are several.

I've tried giving Execution privilage to the \MyProject_bin\* folder, and
Full Trust to each assembly within it. I've also tried giving Full Trust to
the \MyProject_bin\* folder - hoping that everything within it will
"inherit" the Full Trust privilage (probably not a good idea, but I don't
care right now!). Both yeild the same result.

The only time I can get something other that this error is when the
\MyProject_bin\* has Execution, and the MyProject.dll within that folder has
Full Trust. Then, in one of the referenced assemblies (to which no security
policy is assigned), I get a SecurityException - which makes sense. As soon
as I add Full Trust to that assembly, I'm back to the original error above.

Any ideas??

Thanks,

Derrick


.



Relevant Pages

  • OT: Help with Security Policy (VSTO)
    ... Security Policy manually, ... Full Trust to each assembly within it. ... the \MyProject_bin\* folder - hoping that everything within it will ... in one of the referenced assemblies (to which no security ...
    (microsoft.public.dotnet.languages.csharp)
  • Help with Security Policy
    ... I was working on a Visual Studio Tools for Office 2003 Excel project, ... Security Policy manually, ... Full Trust to each assembly within it. ... in one of the referenced assemblies (to which no security ...
    (microsoft.public.dotnet.framework)
  • Re: Strong Name Assembly
    ... just strongnaming your assemblies won't solve your problem. ... You will have to modify the security policy as well. ... To modify the polcy to trust a specific strong name by using the Microsoft ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Confusion about .Net AllowPartiallyTrustedCallers (IE).
    ... To get around the security exceptions that occur; ... The assumption is that strong named assemblies will often have more ... more permissions to perform this task. ... have Full Trust. ...
    (microsoft.public.dotnet.security)
  • RE: some other problems
    ... Upgrading Components That Use the com.ms.wfc.html Package ... loaded from managed assemblies in a version-aware manner. ... NET Framework security policy on the client computer. ...
    (microsoft.public.dotnet.vjsharp)