LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Security Error with .NET assembly on Mapped Drive

Hi all,

 

I'm getting the following error when trying to call a .net assembly that is located on a mapped drive. I've found the following: http://digital.ni.com/public.nsf/allkb/F326A891E72073B486256EEC0006E019 that seems to indicate how to fix this error. However, the error persists. Both the vi and the dll reside together on my mapped drive. This is a mapped drive from parallels (i.e. the files reside on my MAC partition). It's a long story on why it isn't pratical to put them on my local c drive. I would like to find a way to get them to work on this mapped drive.

 

Thanks!

0 Kudos
Message 1 of 5
(2,295 Views)

This should be a system security issue. Network located code has only partial trust. Try to compile the assembly with the AllowPartiallyTrustedCallersAttribute

 

read this:

http://msdn.microsoft.com/en-us/library/system.security.allowpartiallytrustedcallersattribute.aspx

 

Hope it helps

Christian

0 Kudos
Message 2 of 5
(2,289 Views)

Unfortunately that isn't possible in this case as the assembly is from a vendor.

0 Kudos
Message 3 of 5
(2,278 Views)

You need to grant code trust to the network drive. The correct tool to do this is most likely microsofts caspol( http://msdn.microsoft.com/en-us/library/cb6t8dtz(v=vs.80).aspx )

 

 

Should be something like:

caspol -q -machine -addgroup 1 -url file://K:/* FullTrust -name "K map"

0 Kudos
Message 4 of 5
(2,271 Views)

Tried that as well. Still no luck.

0 Kudos
Message 5 of 5
(2,263 Views)