Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created February 8, 2024 15:04
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save bjoerntx/93b0c1ef418bd940307d095d9f52add9 to your computer and use it in GitHub Desktop.
private static void RenameMergeBlocks(SubTextPartCollection subTextParts,
string oldColumnName,
string newColumnName)
{
// iterate through all SubTextParts
foreach (SubTextPart subTextPart in subTextParts)
{
// check if the SubTextPart is a merge block
if (subTextPart.Name == "txmb_" + oldColumnName)
{
// rename the SubTextPart
subTextPart.Name = "txmb_" + newColumnName;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment