none
Could not load file or assembly 'Microsoft.Office.Interop.Outlook'

    Frage

  • I added the option to create a meeting request to a Web page. It works fine in my development machine but when I upload this to the server it doesn’t work.

     

    The application uses the "Microsoft Outlook 11.0 Object Library" COM object in the References and builds find on the developer's machine but not on the server.

     

    I am working on Microsoft Visual Studio 2005, code behind C#

     

    The Bin folder of the Web site has these dll files between others:

    Interop.Outlook.dll

    Office.dll

    The web.config has the reference to the COM Object

    <assemblies>

    <add assembly="Microsoft.Office.Interop.Outlook, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"/>

    </assemblies>

     

    The error that I get is

    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

    Parser Error Message: Could not load file or assembly 'Microsoft.Office.Interop.Outlook, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified.

    Line 50:  <add assembly="Microsoft.Office.Interop.Outlook, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"/>

     

    Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.Office.Interop.Outlook, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' could not be loaded.

    Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.Office.Interop.Outlook, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' could not be loaded.

    WRN: Assembly binding logging is turned OFF.
    To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
    Note: There is some performance penalty associated with assembly bind failure logging.
    To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

     

    I tried to solve the problem without success:

      1. Set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1 (DIDN't Work)
      2. Register the component in GAC (Global Assemble Cache) using the configuration Wizard on development machine (DIDNT WORK EITHER)

    Do we need to install Microsoft Office 2003 and add the Office 2003 PIAs to the Build Server?Is this correct? 

    Is there another way to obtain and register the Office 2003 PIA's?

    Any idea how to solve this problem?

     

    Thanks,

     

    Rosita

     

     

     

     

    Dienstag, 27. November 2007 18:36

Antworten

Alle Antworten

  • Hi,

     

    I take it you mean the software does not build because it cannot resolve the Interop.Outlook.dll reference?

     

    I use the Office/Excel Interop references by placing the dlls in a common folder and referencing it in the build using the following.

     

    Code Block
    <AdditionalReferencePath Include="C:\CommonReferences\" />

     

     

     

    Also, you might want to look at the following post:-

     

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=280888&SiteID=1

     

    Cheers,

     

    Kalim

    Mittwoch, 28. November 2007 11:19
  • You don't need to install Outlook on the server by the way. You can install the Redistributable Primary Interop Assemblies:-

     

    http://www.microsoft.com/downloads/details.aspx?familyid=3c9a983a-ac14-4125-8ba0-d36d67e0f4ad

     

    Cheers,

     

     

    Kalim

    Mittwoch, 28. November 2007 11:21
  •  

    Thanks for the replay but I didn't install Office or the PIA's on the server. What I was trying to do was automated Microsoft Outlook on the server, but it seems that this is not a good idea as this article suggested

    "Considerations for server-side Automation of Office"

    (http://support.microsoft.com/default.aspx?scid=kb%3ben-us%3b257757)

     

    Now I am trying to automated Microsoft Outlook from a web page but the application will execute on the client. It will not execute on the server. One of the requierements that we have is that the application should run on the client.

     

    I found this article which explain "how to automate windows applications from web pages" 

    (http://msmvps.com/blogs/alvin/archive/2006/08/03/106622.aspx)

     

    I will go ahead with this and see what happens.

     

    Thanks,

     

    Freitag, 30. November 2007 19:48
  • Hi Ochi,

     

    Just wanted to know how far you have been successful with "automated Microsoft Outlook from a web page but the application will execute on the client" - as mentioned by you.

     

    Thanks

     

    Donnerstag, 24. Januar 2008 09:43
  • Hi
    I am new to .net ,made a application based on MS office word getting this error :

    Line 44: <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> Line 45: <add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/> Line 46: <add assembly="Office, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"/> Line 47: <add assembly="Microsoft.Office.Interop.Word, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"/> Line 48: <add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>

    can anyone tell me what com.dll and a good desc step by step helping a new bie like me to debug it.
    Thanks so much ..solution awaiting.
    Regards
    Shweta
    Donnerstag, 9. Juli 2009 18:48