Could not load file or assembly 'Microsoft.Office.Interop.Word

.net , asp.net Sri Lanka
  • 10 years ago
    my web page C#.net is work properly in my iis .but when i publish in
    another server it give errers.i used vs2005 and ms word 2003.
    but in the server there is no vs2005 or word installed. it has
    only .net frame work installed.folowing the error,

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


    Source Error:


    Line 27: <compilation debug="false">
    Line 28: <assemblies>
    Line 29: <add assembly="Microsoft.Office.Interop.Word,
    Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"/>
    Line 30: <add assembly="Office, Version=11.0.0.0, Culture=neutral,
    PublicKeyToken=71e9bce111e9429c"/>
    Line 31:


    Source File: E:\hris\crisis\web.config Line: 29


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


    should i install word or vs2005 or what is the reason.how can i fixed
    it

    i found that adding dll to the assembly cache in the server would solve the problem is it so should i add the dll in the bin file or what dll should i use.




































  • 10 years ago

    Hi.

    Install the Word in ur production server.

    unless u install the word. it wont be able to refer the component which u r using in interop services.

     

  • 9 years ago
    Hi..

    In this case, how can I  use a interop services ?

    Can u post some code for example pls!

    Tks BRDs
  • 9 years ago

     good solution  which help me  too....

  • 9 years ago

    Tks... but my problem was other...

     I can do....

     For who wants.... I do the WindowControlLibrary and add on webApp....

    Example
     Dim _responseWrite As String = String.Empty
     _responseWrite = " <object id='ObjectOpenOffice' codebase='<dllFileName>.dll' classid='<dllFileName>.dll#Class' style='width: 0px; height: 0px' > "
    _responseWrite += "     <param name='<ParamName>' value='<ParamValue>' /> "
    _responseWrite += " </object> "
     Response.Write(_responseWrite)

     

    Tks All

Post a reply

Enter your message below

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“We should forget about small efficiencies, say about 97% of the time: premature optimization is the root of all evil.” - Donald Knuth