none
Could not load... Microsoft.mshtml

    Question

  • Hi guys can anyone help me. My appliccation works fine on my pc but on others it produces this error. I think it is a problem with the "Microsoft.mshtml.ddl" or the "mshtml.dll" How do I fix this

    I have uploaded a screen shot of the error http://img6.imageshack.us/img6/227/errorgqr.jpg

    Thanks
    See the end of this message for details on invoking 
    just-in-time (JIT) debugging instead of this dialog box.
    
    ************** Exception Text **************
    System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.mshtml, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
    File name: 'Microsoft.mshtml, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
       at Giggig_Web_Dev.Form1.Form1_Load(Object sender, EventArgs e)
       at System.Windows.Forms.Form.OnLoad(EventArgs e)
       at System.Windows.Forms.Form.OnCreateControl()
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl()
       at System.Windows.Forms.Control.WmShowWindow(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ContainerControl.WndProc(Message& m)
       at System.Windows.Forms.Form.WmShowWindow(Message& m)
       at System.Windows.Forms.Form.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
    
    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].
    
    
    
    ************** Loaded Assemblies **************
    mscorlib
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3074 (QFE.050727-3000)
        CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
    ----------------------------------------
    Giggig Web Dev
        Assembly Version: 1.0.0.0
        Win32 Version: 1.0.0.0
        CodeBase: file:///C:/Program%20Files/Giggig/Giggig%20Web%20Dev/Giggig%20Web%20Dev.exe
    ----------------------------------------
    System.Windows.Forms
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
        CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
    ----------------------------------------
    System
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
        CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
    ----------------------------------------
    System.Drawing
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
        CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
    ----------------------------------------
    System.Windows.Forms.Ribbon
        Assembly Version: 1.0.0.0
        Win32 Version: 1.0.0.0
        CodeBase: file:///C:/Program%20Files/Giggig/Giggig%20Web%20Dev/System.Windows.Forms.Ribbon.DLL
    ----------------------------------------
    NetSpell.SpellChecker
        Assembly Version: 2.1.7.41329
        Win32 Version: 2.1.7.41329
        CodeBase: file:///C:/Program%20Files/Giggig/Giggig%20Web%20Dev/NetSpell.SpellChecker.DLL
    ----------------------------------------
    edtFTPnet
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.0.0
        CodeBase: file:///C:/Program%20Files/Giggig/Giggig%20Web%20Dev/edtFTPnet.DLL
    ----------------------------------------
    System.Configuration
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3053 (netfxsp.050727-3000)
        CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
    ----------------------------------------
    System.Xml
        Assembly Version: 2.0.0.0
        Win32 Version: 2.0.50727.3074 (QFE.050727-3000)
        CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
    ----------------------------------------
    
    ************** JIT Debugging **************
    To enable just-in-time (JIT) debugging, the .config file for this
    application or computer (machine.config) must have the
    jitDebugging value set in the system.windows.forms section.
    The application must also be compiled with debugging
    enabled.
    
    For example:
    
    <configuration>
        <system.windows.forms jitDebugging="true" />
    </configuration>
    
    When JIT debugging is enabled, any unhandled exception
    will be sent to the JIT debugger registered on the computer
    rather than be handled by this dialog box.
    
    
    

    Giggig Enterprises http://www.giggig.co.uk/
    Sunday, July 12, 2009 4:20 PM

Answers

  • The target machine is missing the required PIA.  I've never found a place to download it.  As long as your app doesn't interact with other DLLs that use types from this interop library, you can create your own.  Select the MSHTML node in your project's References and change Copy Local to True.  Build.  That produces the Microsoft.mshtml.dll interop library in your build directory.  Copy it along with your .exe to the target machine.

    Hans Passant.
    • Marked as answer by Giggig guy Sunday, July 12, 2009 7:08 PM
    Sunday, July 12, 2009 5:58 PM
    Moderator

All replies

  • The target machine is missing the required PIA.  I've never found a place to download it.  As long as your app doesn't interact with other DLLs that use types from this interop library, you can create your own.  Select the MSHTML node in your project's References and change Copy Local to True.  Build.  That produces the Microsoft.mshtml.dll interop library in your build directory.  Copy it along with your .exe to the target machine.

    Hans Passant.
    • Marked as answer by Giggig guy Sunday, July 12, 2009 7:08 PM
    Sunday, July 12, 2009 5:58 PM
    Moderator
  • Thanks this didnt solve the problem, but I added the dll to the setup's file system and it works fine now.

    Thanks for your help
    Giggig Enterprises http://www.giggig.co.uk/
    Sunday, July 12, 2009 7:08 PM
  • I'm search and see this topic. When i added the dll to setup file and built my project with x86. With 32 bit it works fine but with 64 bit, i got this error 

    "Could not load file or assembly 'Microsoft.mshtml, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified".

    I run windows 7 32bit and 64bit. Any idea for this problem ? I get headache a long time about it.

    Wednesday, April 27, 2011 8:07 AM
  • Did you find an answer . I am having the same issue for a while....Thanks
    Wednesday, May 04, 2011 11:03 PM