Code Access Security
In my work environment, I often work off a network drive.
Whenever I open a project on the mapped drive, .Net tells me that
the code is not fully trusted because it is located on a network drive.
This causes a security exception whenever I execute code that involves
Does anyone know how to tell .Net to trust a specified network drive?
I have looked at some of the code access admin tool information. Most of
it looks like it is for granting permission to a particular piece of code
not to a drive.
Re: Code Access Security
> Does anyone know how to tell .Net to trust a specified network drive?
> I have looked at some of the code access admin tool information. Most of
> it looks like it is for granting permission to a particular piece of code
You are running afoul of Code Access Security which .NET uses to determine
the security privileges that a particular piece of code is granted. If you
check on the Microsoft .NET Framework Configuration tool from your
Administrative tools, you'll be able to adjust the security permissions.
One option for intranet scenarios is to sign your code with a strong name
key and then give that key elevated permissions. For info, see (beware of
You can use the sn.exe tool to generate a .snk key file.
Hope this helps,
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center