Created
June 10, 2024 11:47
-
-
Save bjoerntx/715716e691f630fbe379ece27dabd0c6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using (TXTextControl.ServerTextControl tx = new TXTextControl.ServerTextControl()) | |
{ | |
tx.Create(); | |
TXTextControl.LoadSettings loadSettings = new TXTextControl.LoadSettings() | |
{ | |
PDFImportSettings = TXTextControl.PDFImportSettings.GenerateLines | |
}; | |
tx.Load("invoice.pdf", TXTextControl.StreamType.AdobePDF, loadSettings); | |
// Write document meta data to the console | |
Console.WriteLine($"Author: {loadSettings.Author}"); | |
Console.WriteLine($"Subject: {loadSettings.DocumentSubject}"); | |
Console.WriteLine($"Title: {loadSettings.DocumentTitle}"); | |
Console.WriteLine($"Creation Date: {loadSettings.CreationDate}"); | |
Console.WriteLine($"Application: {loadSettings.CreatorApplication}"); | |
foreach (string keyword in loadSettings.DocumentKeywords) | |
{ | |
Console.WriteLine($"Keyword: {keyword}"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment