in

SharePoint Blogs

The Best Place for SharePoint-related Blogs

Rajiv and Michael's SharePoint discoveries and musings...

December 2006 - Posts

  • TIP: DLL in GAC, but cannot be accessed through Sharepoint site ("Could not load type") ? Try this fix...

    Symptom:

    We ran into a strange issue recently. We had deployed a signed DLL to the Global Assembly Cache (GAC), and assumed
    that it would be available to all applications on  the web server.

    For some reason, it turned out that one of these DLLs in the GAC was not being resolved by our SharePoint application
    unless the dll was copied into the \bin folder of the application as well.

    The above shows the error that the Sharepoint Application was throwing if the DLL was in the GAC only, but not
    copied over to the \bin folder of  the virtual.

    Resolution:

    After some research, we determined that we had to add a line to the web.config of our SharePoint web application,
    as follows:

    The copy of the DLL could then be removed from the \bin folder leaving only the one copy in the GAC.

    Hope this helps other developers.

    - Rajiv


Need SharePoint Training? Attend a SharePoint Bootcamp!

Posts (c) their respective authors. Everything else (c) 2007 SharePoint Experts