ContextMenu::PlacementRectangle Property
.NET Framework (current version)
Gets or sets the area relative to which the context menu is positioned when it opens.
Assembly: PresentationFramework (in PresentationFramework.dll)
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 | None |
The following example shows how to use the PlacementRectangle property and specify where the ContextMenu is placed.
<ContextMenu Placement="Bottom" PlacementRectangle="30,50,0,0">
.NET Framework
Available since 3.0
Available since 3.0
Show: