Export (0) Print
Expand All

GridSplitter.ResizeDirection Property

Gets or sets a value that indicates whether a GridSplitter control resizes rows or columns.

Namespace: System.Windows.Controls
Assembly: PresentationFramework (in presentationframework.dll)
XML Namespace:  http://schemas.microsoft.com/winfx/2006/xaml/presentation

public GridResizeDirection ResizeDirection { get; set; }
/** @property */
public GridResizeDirection get_ResizeDirection ()

/** @property */
public void set_ResizeDirection (GridResizeDirection value)

public function get ResizeDirection () : GridResizeDirection

public function set ResizeDirection (value : GridResizeDirection)

<object ResizeDirection="GridResizeDirection" .../>

Property Value

The GridResizeDirection value that specifies how to determine whether to resize rows or columns. The default value is Auto.

Identifier field

ResizeDirectionProperty

Metadata properties set to true

None

To specify a GridSplitter that resizes rows or columns, set the HorizontalAlignment and VerticalAlignment properties. If you cannot achieve the desired behavior by setting the HorizontalAlignment and VerticalAlignment properties, change the ResizeDirection or ResizeBehavior default values. For more information, see How to: Resize Rows with a GridSplitter and How to: Resize Columns with a GridSplitter.

The following example shows how to set the ResizeDirection property.

<GridSplitter ResizeDirection="Columns" Width="5"
              Grid.Column="2"  Grid.RowSpan="2"/>

myGridSplitter.ResizeDirection = GridResizeDirection.Columns;

More Code

How to: Resize Rows with a GridSplitter

This example shows how to use a horizontal GridSplitter to redistribute the space between two rows in a Grid without changing the dimensions of the Grid.

How to: Resize Columns with a GridSplitter

This example shows how to create a vertical GridSplitter in order to redistribute the space between two columns in a Grid without changing the dimensions of the Grid.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions

ADD
Show:
© 2014 Microsoft