Installing CuteEditor.dll in the GAC

  •  01-10-2008, 10:39 AM

    Installing CuteEditor.dll in the GAC

    Hi,
     
    I have multiple sites on my webserver, running .net 2.0 that are using the CuteEditor.  Rather than put it in the \bin of each application I want to put it in the GAC.
     
    I have created virtual directories for each application called, "editor" that point to the editor files.
     
    I have following items in the gac:
     
    CuteEditor.dll
     
    I have the following settings in my machine.config:
     

    <appSettings>
       <
    add key="CuteEditorDefaultFilesPath" value="~/editor" />
       <
    add key="CuteEditorLicense" value="G:\Downloads\CuteEditor\CuteEditor.lic" />

     
    In the web.config under C:\windows\Microsoft.NET\Framework\v2.0.50727\CONFIG: I have the following setting:
     

    <add assembly= "CuteEditor, Version=6.0.0.0, Culture=neutral, PublicKeyToken=3858aa6802b1223a" />

     
    When I run the app, the editor comes up (Well, the outline), but no images appear.  The error, found using Fiddler shows many errors "Could not load file or assembly 'CuteEditor' or one of its dependencies. The system cannot find the file specified."  Detailed error message is below.
     
    If I put the CuteEditor.dll in the \bin of the apps, they each work fine.  I want 1 version in the GAC though.
     
    Thanks for your help, Scott
     

    <html>

    <head>

    <title>Parser Error</title>

    <style>

    body {font-family:"Verdana";font-weight:normal;font-size: .7em;color:black;}

    p {font-family:"Verdana";font-weight:normal;color:black;margin-top: -5px}

    b {font-family:"Verdana";font-weight:bold;color:black;margin-top: -5px}

    H1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red }

    H2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon }

    pre {font-family:"Lucida Console";font-size: .9em}

    .marker {font-weight: bold; color: black;text-decoration: none;}

    .version {color: gray;}

    .error {margin-bottom: 10px;}

    .expandable { text-decoration:underline; font-weight:bold; color:navy; cursor:hand; }

    </style>

    </head>

    <body bgcolor="white">

    <span><H1>Server Error in '/' Application.<hr width=100% size=1 color=silver></H1>

    <h2> <i>Parser Error</i> </h2></span>

    <font face="Arial, Helvetica, Geneva, SunSans-Regular, sans-serif ">

    <b> Description: </b>An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

    <br><br>

    <b> Parser Error Message: </b>Could not load file or assembly 'CuteEditor' or one of its dependencies. The system cannot find the file specified.<br><br>

    <b>Source Error:</b> <br><br>

    <table width=100% bgcolor="#ffffcc">

    <tr>

    <td>

    <code><pre>

    <font color=red>Line 1: &lt;%@ WebHandler language=&quot;C#&quot; class=&quot;CuteEditor.LoadHandler,CuteEditor&quot; %&gt;

    </font></pre></code>

    </td>

    </tr>

    </table>

    <br>

    <b> Source File: </b> /editor/Load.ashx<b> &nbsp;&nbsp; Line: </b> 1

    <br><br>

    <b>Assembly Load Trace:</b> The following information can be helpful to determine why the assembly 'CuteEditor' could not be loaded.<br><br>

    <table width=100% bgcolor="#ffffcc">

    <tr>

    <td>

    <code><pre>

    === Pre-bind state information ===

    LOG: User = NT AUTHORITY\SYSTEM

    LOG: DisplayName = CuteEditor

    (Partial)

    LOG: Appbase = file:///D:/p4/dev_scottle_SCOTTLEWIS2008/system/dev/dotnextmaint/TS/Course/Web/UI/Course/CourseHome/Web/UI/

    LOG: Initial PrivatePath = D:\p4\dev_scottle_SCOTTLEWIS2008\system\dev\dotnextmaint\TS\Course\Web\UI\Course\CourseHome\Web\UI\bin

    Calling assembly : (Unknown).

    ===

    LOG: This bind starts in default load context.

    LOG: Using application configuration file: D:\p4\dev_scottle_SCOTTLEWIS2008\system\dev\dotnextmaint\TS\Course\Web\UI\Course\CourseHome\Web\UI\web.config

    LOG: Using host configuration file: \\?\C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet.config

    LOG: Using machine configuration file from C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\config\machine.config.

    LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).

    LOG: The same bind was seen before, and was failed with hr = 0x80070002.

    </pre></code>

    </td>

    </tr>

    </table>

    <br>

    <hr width=100% size=1 color=silver>

    <b>Version Information:</b>&nbsp;Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

    </font>

    </body>

    </html>

    <!--

    [FileNotFoundException]: Could not load file or assembly 'CuteEditor' or one of its dependencies. The system cannot find the file specified.

    at System.RuntimeTypeHandle._GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, Boolean loadTypeFromPartialName)

    at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)

    at System.RuntimeType.PrivateGetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)

    at System.Type.GetType(String typeName, Boolean throwOnError)

    at System.Web.UI.SimpleWebHandlerParser.GetType(String typeName)

    [HttpParseException]: Exception of type 'System.Web.HttpParseException' was thrown.

    at System.Web.UI.SimpleWebHandlerParser.GetType(String typeName)

    at System.Web.UI.SimpleWebHandlerParser.GetTypeToCache(Assembly builtAssembly)

    at System.Web.Compilation.SimpleHandlerBuildProvider.GetGeneratedType(CompilerResults results)

    at System.Web.Compilation.BuildProvider.CreateBuildResult(CompilerResults results)

    at System.Web.Compilation.BuildProvider.GetBuildResult(CompilerResults results)

    at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath)

    at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile)

    at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile)

    at System.Web.UI.SimpleHandlerFactory.System.Web.IHttpHandlerFactory2.GetHandler(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)

    at System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig)

    at System.Web.HttpApplication.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()

    at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

    -->

View Complete Thread