Skip to content

Instantly share code, notes, and snippets.

@bjoerntx

bjoerntx/test.cs Secret

Created July 7, 2023 08:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/1e4983fd546312a8a3502b94226a231e to your computer and use it in GitHub Desktop.
Save bjoerntx/1e4983fd546312a8a3502b94226a231e to your computer and use it in GitHub Desktop.
using (TXTextControl.ServerTextControl tx = new TXTextControl.ServerTextControl()) {
tx.Create();
TXTextControl.LoadSettings loadSettings = new TXTextControl.LoadSettings();
tx.Load("mypdf.pdf", TXTextControl.StreamType.AdobePDF, loadSettings);
foreach (TXTextControl.EmbeddedFile embeddedFile in loadSettings.EmbeddedFiles) {
System.IO.File.WriteAllText(
embeddedFile.FileName,
Encoding.ASCII.GetString((byte[])embeddedFile.Data));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment