When trying to create an instance of a Persits component under .NET the following error occurs:Retrieving the COM class factory for component with CLSID {<GUID>} failed due to the following error: 80040154.
<GUID> is one of the following values, depending on the component being created:
{794D671E-F0F0-11D2-BEB0-009027438003} (AspEmail)
{B72DF070-28A4-11D3-BF19-009027438003} (AspEncrypt)
{6A3450E6-BE0A-45A1-815B-9A4494D1CCBF} (AspGrid)
{FC7A96B0-4DEC-11D4-9C83-0080ADA78DDF} (AspJpeg)
{88578679-272B-40C0-B1FD-C3409381A450} (AspPDF)
{B4E1B2EC-151B-11D2-926A-006008123235} (AspUpload)
{D474601E-C057-11D2-97CD-006008123235} (AspUser)
In most cases, this error can be fixed on a 64-bit Windows server by installing both the 32-bit and 64-bit version of the component at the same time. If this does not fix the error, please continue reading.This error message is very ambiguous as it may be caused by several different problems. It is therefore advisable that a classic ASP script calling CreateObject with the proper ProgID be run to see a more informative error message. For example, if you are having the problem with AspEmail, the script to run would be
<%
Set Mail = Server.CreateObject("Persits.MailSender")
%>In this example, "Persits.MailSender" is AspEmail's ProgID. The following table lists all of Persits Software component ProgIDs:
Component ProgID AspEmail "Persits.MailSender" AspEncrypt "Persits.CryptoManager" AspGrid "Persits.Grid" AspJpeg "Persits.Jpeg" AspPDF "Persits.PDF" AspUpload "Persits.Upload" AspUser "Persits.AspUser" Most probably, this simple script will generate a run-time error. Search for the error message in this Knowledge Base and follow the instructions.
If running the classic ASP script is impossible or impractical, the following troubleshooting steps should be followed:
- Make sure the component DLL is registered on the server, and proper permissions are set on the HKEY_CLASSES_ROOT registry keys. For more information, see this article: PS01032622.
- Make sure there is no mismatch between the 32-bit IIS mode and 64-bit version of the component DLL, or vice versa (only applicable if the web server runs the 64-bit version of Windows.) For more information, see this article: PS080519170.
- Make sure the NTFS permissions are properly set on the component DLL. For more information, see this article: PS01032115.
- Make sure proper registry permissions are set on the HKEY_CLASSES_ROOT\TypeLib registry keys. For more information, see the article corresponding to the component you are using:
Component Article AspEmail PS01030813 AspEncrypt PS01030812 AspGrid PS01030810 AspJpeg PS01030814 AspPDF PS040115121 AspUpload PS0103069 AspUser PS01030811
This article applies to AspUpload, AspEmail, AspJpeg, AspGrid, AspEncrypt, AspUser, and AspPDF.