PlacementTarget Attached Property

ContextMenuService.PlacementTarget Attached Property


Gets or sets the parent control of the ContextMenu.

Namespace:   System.Windows.Controls
Assembly:  PresentationFramework (in PresentationFramework.dll)

See GetPlacementTarget, SetPlacementTarget

Property Value

Type: System.Windows.UIElement

The UIElement that is the parent of the ContextMenu.

You can position a ContextMenu by setting the PlacementTarget, PlacementRectangle, Placement, HorizontalOffset, and VerticalOffsetProperty properties. These properties behave the same as they do for a Popup. For more information, see Popup Placement Behavior.

Identifier field


Metadata properties set to true


Return to top
© 2015 Microsoft