Last active
October 20, 2021 19:49
-
-
Save bjoerntx/3ec98f713d572bb39ca7c64d52a2fe23 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
private void Mm_BlockRowMerged( | |
object sender, | |
TXTextControl.DocumentServer.MailMerge.BlockRowMergedEventArgs e) { | |
using (TXTextControl.ServerTextControl tx = new TXTextControl.ServerTextControl()) { | |
tx.Create(); | |
tx.Load(e.MergedBlockRow, TXTextControl.BinaryStreamType.InternalUnicodeFormat); | |
// find all tables in a block and flag cell 1,1 | |
if (tx.Tables.GetItem() != null) { | |
tx.Tables.GetItem().Cells.GetItem(1, 1).Name = "block_identifier"; | |
} | |
byte[] data; | |
tx.Save(out data, TXTextControl.BinaryStreamType.InternalUnicodeFormat); | |
e.MergedBlockRow = data; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment