I need to use VB to set the document properties (title, subject, keywords, author) of existing pdf documments.
I was led to believe that using just the Common Driver Interface (cdintf210.dll) I can achieve this.
Based on the tech documentation that comes with that dll, I can see these are all simple Read/Write properties of the Document object.
However, I don't see any code or function calls that let me declare and instantiate the Document object (based on a given file path & name).
Any hints?
Just setting pdf document properties
Hello,
Here is a sample VB code on setting the Tiltle, subject ect... using the Document interface of CDIntfEx.
Here is a sample VB code on setting the Tiltle, subject ect... using the Document interface of CDIntfEx.
Hope this helps !Private Sub changedocinfo_Click()
Dim pdfdoc As New CDIntfEx.Document
pdfdoc.Open ("C:\Temp\Test.pdf")
pdfdoc.Title = "Some Title"
pdfdoc.Author = "Some Author"
pdfdoc.Creator = "Some Creator"
pdfdoc.Subject = "Some Subject"
pdfdoc.Keywords = "Some Keywords"
pdfdoc.Save ("C:\Temp\NewTest.pdf")
Set pdfdoc = Nothing
End Sub