0

Got this error when deploying a VB6 / .NET application on a 64-bit Windows 2008 machine.

Unable to cast COM object of type 'MSScriptControl.ScriptControlClass' to 
interface type 'MSScriptControl.IScriptControl'. This operation failed because the 
QueryInterface call on the COM component for the interface with IID '{xxx}' failed 
due to the following error: Error loading type library/DLL. (Exception from HRESULT:
0x80029C4A (TYPE_E_CANTLOADLIBRARY)).
David
  • 1,601
  • 3
  • 22
  • 33

1 Answers1

1

To solve, run the following command

RUN CMD AS ADMINISTRATOR

regsvr32 C:\Windows\SysWOW64\MSScript.ocx

David
  • 1,601
  • 3
  • 22
  • 33
  • Pretty crude, never just ignore corruption of the registry. Find out first *why* it is corrupted before you start changing it and potentially do more damage. – Hans Passant Nov 21 '13 at 11:37
  • I agree the answer could do with a bit more explaining. The solution remains the same though. – David Nov 21 '13 at 12:20