1. Call the static method ‘GetAdornerLayer()’, to get the AdornerLayer associated with the UIElement.
2. Call the ‘Add()’ method to bind the Adorner to the target UIElement.
[C#]
AdornerLayer adornerLayer = AdornerLayer.GetAdornerLayer(myTextBox);
adornerLayer.Remove(new ControlAdorner(myTextBox));
Share with