CleanupAdorner Method
- Last UpdatedSep 29, 2026
- 1 minute read
Similar to Dispose() pattern. CleanupAdorner releases and cleans up objects associated with an adorned element.
Monitoring of the underlying hierarchy item stops if the adorner's UI element is the last one referencing the underlying hierarchy item.
'Declaration
Public Shared Sub CleanupAdorner( _
ByVal adornedElement As FrameworkElement _
)
public static void CleanupAdorner(
FrameworkElement adornedElement
)
public:
static void CleanupAdorner(
FrameworkElement^ adornedElement
)
Parameters
- adornedElement
- The element to adorn.
Target Platforms:
- Windows 10 Enterprise, IoT Enterprise 2019 LTSC (1809)
- Windows 10 Enterprise 2021 LTSC (21H2)
- Windows 10 IoT Enterprise (Only) 2021 LTSC (21H2)
- Windows 11 Enterprise, IoT Enterprise 2024 LTSC 24H2
- Windows Server 2019 LTSC (Datacenter, Essentials, Standard)
- Windows Server IoT 2019 LTSC
- Windows Server 2022 LTSC Standard and Datacenter
- Windows Server 2025 LTSC Standard and Datacenter