Problem with AjaxMin.dll ? TypeLoadException: Inheritance security rules violated while overriding member: 'Microsoft.Ajax.Utilities.ScannerException.GetObjectData'

Topics: Controls
Jul 12, 2013 at 10:50 AM
The only solution I've found to this error is to bypass AjaxMin all together:
<compresswebresource>False</compresswebresource>

[TypeLoadException: Inheritance security rules violated while overriding member: 'Microsoft.Ajax.Utilities.ScannerException.GetObjectData(System.Runtime.Serialization.SerializationInfo, System.Runtime.Serialization.StreamingContext)'. Security accessibility of the overriding method must match the security accessibility of the method being overriden.]
Microsoft.Ajax.Utilities.JSParser.ParseStatements() +0
Microsoft.Ajax.Utilities.JSParser.Parse(CodeSettings settings) +204
Microsoft.Ajax.Utilities.Minifier.MinifyJavaScript(String source, CodeSettings codeSettings) +556
BlogEngine.Core.Web.Scripting.JavascriptMinifier.Minify(String script) in JavascriptMinifier.cs:94
BlogEngine.Core.Web.Scripting.WebResourceFilter.RetrieveRemoteFile(String file) in WebResourceFilter.cs:328
BlogEngine.Core.Web.Scripting.WebResourceFilter.Close() in WebResourceFilter.cs:141
System.Web.HttpWriter.FilterIntegrated(Boolean finalFiltering, IIS7WorkerRequest wr) +188
System.Web.HttpResponse.FilterOutput() +104
System.Web.CallFilterExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +49
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69