Showing posts with label activex. Show all posts
Showing posts with label activex. Show all posts

Tuesday, March 13, 2012

System.Security.SecurityException: That assembly does not allow

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.
I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled
I am really lost on how to make this work any help will be appreciated
JohnDid this work for you?
I have a .NET class that i have made com visible and the client is
trying to access it using Visual Objects over a network shar and is
getting the same exception.
i have added the AllowPartiallyTusterCallers attribute to my
assemblyinfo.cs but is hasnt fixed it.
i have ben trying to test using something non .NET (VB 6.0) but i cant
even reference the tlb or dll but i think that is a VB 6.0 issue.
if anyone has any suggestions pleae let me know.
the Client has advised that the dll works if it is copied locally.
thanks

System.Security.SecurityException: That assembly does not allowpartially trusted callers.

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.

I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled

I am really lost on how to make this work any help will be appreciated

Johnyou prolly have to add this to your code:

[assembly: AllowPartiallyTrustedCallers]

--
Dominick Baier (http://www.leastprivilege.com)

Developing More Secure Microsoft ASP.NET 2.0 Applications (http://www.microsoft.com/mspress/books/9989.asp)

Quote:

Originally Posted by

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.
>
I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled
>
I am really lost on how to make this work any help will be appreciated
>
John
>