WPF FlexViewer memory leak

Posted by: sebastian-jn.k on 13 July 2026, 8:26 am EST

  • Posted 13 July 2026, 8:26 am EST

    .NET 4.8

    C1.WPF.FlexViewer 4.6.20251.877

    Hello,

    I’m experiencing a serious memory leak with the C1FlexViewer.

    The C1FlexViewer instance remains in Memory and is not being released properly.

    To reproduce the issue, I created a sample project with the following scenarios:

    WPF Window → C1FlexViewer

    WPF Window → Microsoft DocumentViewer

    WPF Window ->ElementHost-> C1FlexViewer

    WPF Window ->ElementHost-> Microsoft DocumentViewer

    In both scenarios using C1FlexViewer, a significant memory leak remains (several megabytes).

    According to heap analysis, the C1FlexViewer instance is never garbage collected.

    In our application, we use C1FlexViewer together with and ElementHost.

    I used Microsoft DocumentViewer as a reference for expected behavior.

    Even when hosted inside an ElementHost, the Microsoft DocumentViewer is released correctly and does not leave a significant memory leak.

    The same is true for the scenario without an ElementHost

    Could you please help me understand how to resolve this issue?

    Is there a known workaround or recommended cleanup procesdure?

    Best regards from Germany!

    FlexViewerMemoryLeak.zip

  • Posted 14 July 2026, 5:00 am EST

    Hi Sebastian,

    Thanks a lot for sharing the complete sample project. We were able to reproduce the memory leak you mentioned. We then tested the same project with the latest 2026v1 release, which significantly improved the memory management. However, we could still observe some FlexViewer objects remaining in the heap.

    We have shared our observations with the development team for further investigation and will let you know of any updates as soon as possible.

    [Internal Tracking ID: C1XAML-39928]

    Best Regards,

    Kartik

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels