[Last Call] Learn how to a build a cloud-first strategyRegister Now


Assembly does not allow partially trusted callers

Posted on 2008-11-19
Medium Priority
Last Modified: 2012-06-22
I keep getting this error and no luck fixing:

Exception Details: System.Security.SecurityException: That assembly does not allow partially trusted callers.

Source Error:

Line 1:  <%@ Page Language="VB" ContentType="text/html" %>
Line 2:  <%@ Register TagPrefix="MM" Namespace="DreamweaverCtrls" Assembly="DreamweaverCtrls,version=,publicKeyToken=836f606ede05d46a,culture=neutral" %>
Line 3:  <MM:DataSet
Line 4:  runat="Server"
Line 5:  id="Procedure1"
Question by:Nathan Riley
  • 3
  • 2

Expert Comment

ID: 23011505
Use the Microsoft .NET Framework configurator to give the assembly that tries to use that locked down assembly full trust.

If that doesn't help: create a WCF wrapper around that assembly and let it run in a Windows Service. Consume the WCF wrapper from the asp.net pages.

Kind regards.

Expert Comment

ID: 23011518
BTW: the page will get compiled to a DLL (class assembly) and is placed in the bin folder. Ditch the dynamic recompile and add a strong name for your asp.net assembly. This will easy up the rights management you are battling with.
LVL 12

Author Comment

by:Nathan Riley
ID: 23013744
I'm very new to this and not sure what you mean.  I know I can't mess with the .net config as I'm hosted through godaddy.com

Accepted Solution

illusio earned 2000 total points
ID: 23014175
Phew this seems a common problem. Mostly solved by moving to another provider that can activate the full trust for you...

If this isn't an option you can try the modified controls found here:
(extract the mxp file using the adobe extension manager)

Or you can take a look in the code that should be on this location or similar:
C:\Program Files\Macromedia\Dreamweaver 8\Configuration\ServerBehaviors\Shared\ASP.Net\Scripts\Source\DreamweaverCtrls.cs
(info found on: http://www.communitymx.com/blog/index.cfm?newsid=709)
In the code file you will have to find the System.Security stuff with RequestPermition and .Deny and .Demand and so.

A last resort would be: don't use those controls. (very disappointing answer - i know)

Kind regards.
LVL 12

Author Comment

by:Nathan Riley
ID: 23015762
Yeah tried that and still not working.  I don't know how to do it without the controls.  Been working on it for a week now.

Featured Post

Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Suggested Courses
Course of the Month18 days, 14 hours left to enroll

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question