Using the Component
Installing XpdfAnalyze
Before using the XpdfAnalyze component, it must be registered on your system. Normally the installer will take care of that for you. If you need to register manually, you can run the command:regsvr32 XpdfAnalyze.dll
Referencing XpdfAnalyze
To use the XpdfAnalyze component in a Visual Studio project, select the "References..." command on the "Projects" menu, go to the "COM" tab, and check the box next to XpdfAnalyze.Instantiating an XpdfAnalyze Object
The code needed to instantiate an XpdfAnalyze object depends on your development environment. In VB6:Dim pdf As XpdfAnalyze.XpdfAnalyze
Set pdf = New XpdfAnalyze.XpdfAnalyze
In ASP VBScript:
Set pdf = Server.CreateObject("Xpdf.XpdfAnalyze")
In VB.net:
Dim pdf As XpdfAnalyze.XpdfAnalyze
pdf = New XpdfAnalyze.XpdfAnalyze()
In C#:
XpdfAnalyze.XpdfAnalyze pdf;
pdf = new XpdfAnalyze.XpdfAnalyze();
In Delphi:
var
pdf: IXpdfAnalyze;
begin
pdf := CoXpdfAnalyze_.Create;
Working with XpdfAnalyze
Once you've instantiated an XpdfAnalyze object, you can load PDF files and retrieve metadata. Typical code looks like this:pdf.loadFile "c:/test/file.pdf"
title = pdf.title
MsgBox "title: " & title