Created
November 13, 2023 17:50
-
-
Save bjoerntx/6dd95abed5f99c66ac7bc054e01a3a9a to your computer and use it in GitHub Desktop.
This file contains 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.Selection selection = new TXTextControl.Selection(); | |
selection.Text = "Hello PDF!"; | |
selection.FontSize = 360; | |
selection.FontName = "Arial"; | |
selection.ForeColor = System.Drawing.Color.Red; | |
tx.Selection = selection; | |
TXTextControl.SaveSettings saveSettings = new TXTextControl.SaveSettings() | |
{ | |
UserPassword = "textcontrol" | |
}; | |
tx.Save("output.pdf", TXTextControl.StreamType.AdobePDF, saveSettings); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment