You are viewing limited content. For full access, please sign in.

Question

Question

Retrieving the COM class factory for component with CLSID {474A00CF-8B0F-4656-A5AC-B450549172B8} failed due to the following error: 8007007e The specified module could not be found. (Exception from HRESULT: 0x8007007E).

asked on March 26

I have been struggling to solve this error for days now, And I find nowhere to get any help on this.. Am using SDK8.2 and what I am trying to accomplish is DocumentExportation. I am using C# and aspx.

When I ran the same scripts in another server it produce no errors.

The following are the source codes I have written to accomplish this..

using System;
using System.Configuration;
using System.Data;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using LFSO80Lib;
using DocumentProcessor80;
using System.Text;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
         
        lbtest.Text = "";
        LFSO80Lib.LFApplication app = new LFSO80Lib.LFApplication();
        LFSO80Lib.LFServer serv = (LFSO80Lib.LFServer)app.GetServerByName("");// Laserfiche Server
        LFSO80Lib.LFDatabase db = (LFSO80Lib.LFDatabase)serv.GetDatabaseByName("");//Repository Name
        LFSO80Lib.LFConnection conn = new LFSO80Lib.LFConnection();//Instatiatianing New Connection
        conn.UserName = ""; //User name
        conn.Password = ""; // "Password;
        conn.Create(db);// Creating new Connection

        


        string id = Request.QueryString["ID"];
        string docType = Request.QueryString["docType"];
        string docTypee = "";

       
        LFSearch mySearch = (LFSearch)db.CreateSearch();
        if(docType == "regCard"){

        mySearch.Command = @"{ LF: LOOKIN = ""Members""} & {[Registration Card]:[Member ID]="+id+"} ";
         docTypee = "Registration Form";

        }else if (docType == "claimDoc")
        {
          mySearch.Command = @"{ LF: LOOKIN = ""Members""} & {[Claims Documents]:[Member ID]="+id+"} "; 
           docTypee = "Claim Documents";  
        }else if (docType == "pensionDoc")
        {

         mySearch.Command = @"{ LF: LOOKIN = ""Members""} & {[Pension]:[Member ID]="+id+"} "; 
          docTypee = "Pension Documents";

        }else if (docType == "corrDoc")
        {

        mySearch.Command = @"{ LF: LOOKIN = ""Members""} & {[Correspondences]:[Member ID]="+id+"} ";
         docTypee = "Correspondences";  

        }else if( docType == "ContrSchedule"){

            mySearch.Command = @"{ LF: LOOKIN = ""Employers""} & {[Contribution Schedule]:[Employer ID]="+id+"} ";
            docTypee = "Contribution Schedule";
        }else if(docType == "empCorrespondences"){

            mySearch.Command = @"{ LF: LOOKIN = ""Employers""} & {[Employer Correspondences]:[Employer ID]="+id+"} ";
            docTypee = "Correspondences Documents";

        }else if(docType == "empRegCard"){

            mySearch.Command = @"{ LF: LOOKIN = ""Employers""} & {[Employer Registration Document]:[Employer ID]="+id+"} ";
            docTypee = "Registration Documents";

        }
        else if(docType == "memBenefits"){

            mySearch.Command = @"{ LF: LOOKIN = ""Members""} & {[Member Claim Documents]:[Member ID]="+id+"} ";
            docTypee = "Member Claim Documents";

        }
       
        mySearch.BeginSearch(true);
                // Instantiates a LFsearchListingParams object.
        LFSearchListingParams NewParams = new LFSearchListingParams();
        NewParams.AddStandardColumn(Column_Type.COLUMN_TYPE_TEMPLATENAME);
        // Sort the results listing by entry name in
        // ascending order.
        NewParams.set_ColumnTypeToSortBy(Column_Type.COLUMN_TYPE_NAME, Sort_Direction.SORT_DIRECTION_ASC);
        // Gets the search results listing.
        LFSearchResultListing ResultListing = (LFSearchResultListing)mySearch.GetSearchResultListing(NewParams, 0);
        // Display the name of the template associated 
        // with each search result
      
        if(ResultListing.RowCount == 0){
            lbtest.Text +="No "+docTypee+" has been Uploaded<br><br>";
            Console.Write(lbtest.Text);
            
            }else if(ResultListing.RowCount == 1){
            lbtest.Text +=ResultListing.RowCount; 
             Console.Write(lbtest.Text);
             ILFCollection AllHits = (ILFCollection)mySearch.GetSearchHits();
             LFSearchHit Hit = (LFSearchHit)AllHits[1];
            ILFEntry EntryHit = (ILFEntry)Hit.Entry;
            
            lbtest.Text += EntryHit.FullPath;
            Console.WriteLine(lbtest.Text);

        LFSO80Lib.ILFEntry disps = (LFSO80Lib.ILFEntry)db.GetEntryByPath(EntryHit.FullPath);

       if (disps.EntryType == LFSO80Lib.Entry_Type.ENTRY_TYPE_DOCUMENT){
            lbtest.Text +="Document has been Found<br><br>";
            Console.Write(lbtest.Text);
           
        LFSO80Lib.LFDocument doc = (LFSO80Lib.LFDocument)disps;
        LFSO80Lib.LFDocumentPages docpages = (LFSO80Lib.LFDocumentPages)doc.Pages;
    
       DocumentExporter exporter = new DocumentExporter();
        exporter.AddSourcePages(docpages);
        exporter.Format = DocumentProcessor80.Document_Format.DOCUMENT_FORMAT_PDF;
       
        exporter.Scale = 8000;	
        byte[] imageStream = null;
        imageStream = (byte[])exporter.Export();
        doc.Dispose();
        conn.Terminate();
        Response.ContentType = "Application/PDF";
        Response.BinaryWrite(imageStream);
        Response.End();
        
        }
       
        }else{

            lbtest.Text +="More than One Document has been Found<br><br>";
            Console.Write(lbtest.Text);
            for(int i=1; i<=ResultListing.RowCount; i++){
               
             ILFCollection AllHits = (ILFCollection)mySearch.GetSearchHits();
             LFSearchHit Hit = (LFSearchHit)AllHits[i];
            ILFEntry EntryHit = (ILFEntry)Hit.Entry;
            
            // lbtest.Text += EntryHit.FullPath+" "+ Environment.NewLine;
            lbtest.Text += i+". <a href='https://172.20.20.180/interface-2/docByPath.aspx?path="+EntryHit.FullPath+"' target=\"docss\">"+EntryHit.Name+"</a><br>";
            Console.WriteLine(lbtest.Text);
            }
           
        }
      
        

        conn.Terminate();

    }
    
}

 

0 0

Answer

SELECTED ANSWER
replied on March 28

yes @████████i changed both.. I was getting an error on line 091 seems like LFSO80Lib doesnt recognize it.. I deleted and used the PDFExporter Library to export docs in pdf as DocumentProcessor82 does not have DOCUMENT_FORMAT_PDF..

 

Thanks for your help all..

0 0

Replies

replied on March 26

Did you install the SDK runtime on this machine? Do you have a DocumentProcessor80.dll in C:\Program Files (x86)\Common Files\Laserfiche\LFObjects?

0 0
replied on March 28

Yes, SDK 8.0 has been installed and the DocumentProcessor80.dll is available. @████████and for @████████I have already enabled 32 bit applications in Application Pool. 

 

So far I have changed from DocumentProcessor80 to DocumentProcessor82 but it doesnt support pdf Exportation

0 0
replied on March 28

Are you compiling your application as 32-bit? If it's 64-bit or Any CPU, then on 64-bit Windows it will try to run as 64-bit.

The code above specifically uses LFSO80 and DocumentProcessor80. Did you change both? If you're still getting the exact same error, your code is not properly updated.

0 0
SELECTED ANSWER
replied on March 28

yes @████████i changed both.. I was getting an error on line 091 seems like LFSO80Lib doesnt recognize it.. I deleted and used the PDFExporter Library to export docs in pdf as DocumentProcessor82 does not have DOCUMENT_FORMAT_PDF..

 

Thanks for your help all..

0 0
replied on March 29

You're welcome. LFSO80Lib is still LFSO80 that's why it wasn't recognizing it.

0 0
replied on March 26

Hola Emmanuel,

In addition to Miruna mentioned, try to change the execution of your web application to 32 bits, open IIS, go to the application group, select the group associated to your web, clic the advanced configuration and change value to "True" (applications of 32 bits). View image

regards,
Marco.

0 0
replied on August 19

Dears , I'm getting the same error , I applied the suggested solution but it's not working.

Is there a missing configuration?

 

0 0
replied on August 19

Do you know what version of the Laserfiche SDK you're using in your project. The GUID above is for LFSO92.dll.

0 0
replied on August 19

9.2.0.0

0 0
replied on August 19

If you look in the registry under that class id, it will tell you what dll it is trying to load. It will be at "HKEY_CLASSES_ROOT\CLSID\{18180389...". It should point to something like C:\Program Files\Common Files\Laserfiche\9.2\DocumentProcessor92.dll. I'd expect that the dll itself is there, but maybe one of its dependencies is missing. I would recommend re-running the SDK installer.

0 0
replied on August 20

This is the content of the folder

0 0
replied on August 23

Have you confirmed that is the location specified in the registry? Have you repaired the installation or investigated missing dependencies? Dependency Walker can be helpful.

0 0
replied on August 25

It's now working after uninstalling SDK10 and installing SDK9.2.

It's working with SDK10 on other machines without issues !

 

 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.