Created
June 8, 2023 08:26
-
-
Save bjoerntx/f898511d2c1cf26a5784cb5c8806aa79 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
TXTextControl.LoadSettings ls = new TXTextControl.LoadSettings() { | |
ApplicationFieldFormat = TXTextControl.ApplicationFieldFormat.MSWord, | |
LoadSubTextParts = true }; | |
using (TXTextControl.ServerTextControl serverTextControl = | |
new TXTextControl.ServerTextControl()) { | |
serverTextControl.Create(); | |
serverTextControl.Load("template.docx", TXTextControl.StreamType.WordprocessingML, ls); | |
using (MailMerge mailMerge = new MailMerge()) { | |
mailMerge.TextComponent = serverTextControl; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment