Retrieving the COM class factory for component with CLSID {GUID} failed due to the following error: 80040154

If this exception is in a Website or a WebApplicaiton,

first set application pool (in IIS) to disable 32-bit Applications (under advanced settings of a pool).

open Internet Information Services (IIS) Manager

select Application Pools

select the pool which your app uses

click Advanced settings

set Enable 32-Bit Applications to true


If this works, then no need to proceed to following attempt.


In Visual Studio Open Project Properties (right click on project in Solution Explorer and choose properties), in the Build tab (at right side of the window) change Platform target combo box value to X86.

Rebuild the project and then rebuild the solution, if exists

Posted Article in Programming
Login InOR Register