Skip to content

stripESRILabelMarkup() does not strip dynamic text #150

@andrewphilipsmith

Description

@andrewphilipsmith

When stripping out ESRI markup from Text/Label Elements, the presence of <dyn .... > tag (associated with Data Driven Pages) causes the PageLayoutProperties.stripESRILabelMarkup to fail. For example these test cases all fail. (Each of them have been manually tested by entering them into a text element in ArcMap.)

// Dynamic Page markup, when DDP is disabled
[TestCase(@"11 - The<dyn type='page' property='Name'/> quick brown fox", @"11 - The quick brown fox")]
// Dynamic Page markup, when DDP is disabled
[TestCase(@"12 - The <dyn type='page' property='Name' emptyStr='quick'/> brown fox", @"12 - The quick brown fox")]
// Dynamic Page markup, when DDP is disabled and formating markup
[TestCase(@"13 - The <dyn type='page' property='Name' emptyStr='quick'/> brown <BOL>fox</BOL>", @"13 - The quick brown fox")]
public void TestStripESRILabelMarkup(string input, string expectedOutput)

The other test cases pass.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions