Welcome Guest! To enable all features, please Login or Register.



Last Go to last post Unread Go to first unread post
#1 Posted : Sunday, March 2, 2014 10:12:24 PM(UTC)


Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

This functionality is only available in our .NET classes using PDFDocument.ParsePages() Method, and there is no direct way to do it using the C DLL functions.

The attached solution shows how to be able to parse objects from PDF files and save the results to a TXT file using our .NET DLLs in C++ application. The solution contains two projects:
1) CustomDLL project: C# DLL that includes the implementation of the Parse objects.
2) PDFDocument Project: C++ Console Application that uses the CustomDLL to call the PDFDocument.ParsePages() Method.

In order to successfully run the solution, please do the following:
1. Download the attached ZIP file and extract it to your hard drive.
2. Open the solution using VS2010.
3. Build the two projects.
4. Copy the Leadtools.PdfEngine.dll next to the newly created CustomDLL.dll.

5. Register the Managed DLL for use with Native C++. You can do that as follows:
a. Run Visual Studio Command Prompt (2010). You can find it in Start Menu -> All Programs -> Microsoft Visual Studio 2010 -> Visual Studio Tools.
b. Change the directory path of the directory that contains CustomDLL.dll.
c. Execute the below command:
RegAsm.exe CustomDLL.dll /tlb:CustomDLL.tlb /codebase

6. In the PDFDocument.cpp, change the PDFFileName and TXTFileName variables if needed.
7. Rebuild the solution and make sure there are no errors.
8. Run the solution, and it should open the folder that contains the generated TXT file if everything worked successfully.

If you face any problem using the above steps, send an email to support@leadtools.com from a valid email address and mention this forum post, and include full details about the problem.

Note: This solution is also helpful to know how to use .NET methods in a C/C++ application.
File Attachment(s):
PDFDocument.zip (441kb) downloaded 156 time(s).

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.061 seconds.