Quantcast
Channel: General Office Development forum
Viewing all articles
Browse latest Browse all 2257

Microsoft.Office.Interop.MSProject.dll" was loaded but the entry-point DllRegisterServer was not found

$
0
0

1/ General:

We need your advice to register the Microsoft.Office.Interop.MSProject.dll correctly to fix the following problem:

“System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {1019A320-508A-11CF-A49D-00AA00574C74} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).”

After registering it by running the command “regsvr32 Microsoft.Office.Interop.MSProject.dll” in the folder that contains that dll, we got the following error message:

•The module "Microsoft.Office.Interop.MSProject.dll" was loaded but the entry-point DllRegisterServer was not found. Make sure that "Microsoft.Office.Interop.MSProject.dll" is a valid DLL or OCX file and then try again.

2/ Detail:

We want to trigger to update the project management file from SQL Server.  Our Visual basic application works without any problems. Then, we used that source code to create the StoredProcedures class in our project, then compiled that project to the dll file as following:

C:\MSProject\ClassLibrary3>vbc  /link:"Interop.Microsoft.Office.Interop.MSProject.dll" /target:library C:\MSProject\ClassLibrary3\AddProjectTaskHours.vb

After that, we copied the AddProjectTaskHours.dll to the server that contains our SQL Server database. Then, we followed the standard instruction (https://technet.microsoft.com/en-us/library/ff878250(v=sql.110).aspx and https://msdn.microsoft.com/en-us/library/ms131094.aspx) to create assembly from AddProjectTaskHours.dll, and then created the stored procedure to call CLR stored procedure as external name AddProjectTaskHours.[StoredProcedures].AddProjectTaskHours as the following sample command:

G:\MS Project DLLs\AddProjectTaskHours>sqlcmd -E -I -i install.sql -v root = "G:\MS Project DLLs\"

Changed database context to 'ApexNAVDEV_20150720'.

After executing that stored procedure, we got the error message that contains:“System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {1019A320-508A-11CF-A49D-00AA00574C74} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).”

To fix that class registered problem, we ran the following command:

C:\Program Files (x86)\Microsoft Visual Studio 11.0\Visual Studio Tools for Office\PIA\Office14>regsvr32 Microsoft.Office.Interop.MSProject.dll

Then, it threw the following errors as in the screen shot:

Alternately, we found an advice in the http://www.experts-exchange.com/Programming/Languages/Visual_Basic/Q_20101341.html URL saying that if it is not an active dll, then we don't have to register. Instead, we only need to paste it in system directory. We did it by copying the dll file to C:\Windows\System, but it still did not work.

Other option is to run “regedit" (register editor) to fix corrupt or invalid registry entries of Microsoft.Office.Interop.MSProject.dll file manually, but we don’t want to do that until we receive the clear and specific instruction from Microsoft, not from the third party, to edit the windows registry based on the suggestion we read from the following URL: http://www.fixerrorhelps.com/fix-pc-error/how-to-fix-Microsoft.Office.Interop.MSProject.dll-error.html

They suggested not to clean the system registry manually because a slight mistake may make our software unpredictable or even crash our system.


Viewing all articles
Browse latest Browse all 2257

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>