Version

SetPositionInNormalMode Method

Moves the UltraTile to a new position within the UltraTilePanel.
Syntax
'Declaration
 
Public Function SetPositionInNormalMode( _
   ByVal newPositionInNormalMode As Point, _
   ByVal shouldAnimate As Boolean _
) As Boolean
public bool SetPositionInNormalMode( 
   Point newPositionInNormalMode,
   bool shouldAnimate
)

Parameters

newPositionInNormalMode
The zero-based row and column index values where the UltraTile should be moved.
shouldAnimate
Inciating whether the tile should animate moving to its new position.

Return Value

True if the UltraTile was successfully repositioned; False otherwise.
Exceptions
ExceptionDescription
System.InvalidOperationException The UltraTilePanel is not currently in the normal mode.
System.ArgumentOutOfRangeExceptionThe X or Y values of newPositionInNormalMode is less then zero.
Example
The following code demonstrates how to reposition an UltraTile at run-time.

Imports System.Windows.Forms
Imports Infragistics.Win
Imports Infragistics.Win.Misc

' Get the first tile in the UltraTilePanel
Dim tile As UltraTile = Me.UltraTilePanel1.Tiles(0)

' If the first tile is not in the top-left corner of the UltraTilePanel, 
' reposition it to the top-left corner but prevent it from animating to the new position.
If Not tile.PositionInNormalMode = New Point(0, 0) Then
    tile.SetPositionInNormalMode(New Point(0, 0), False)
End If
using System.Windows.Forms;
using Infragistics.Win;
using Infragistics.Win.Misc;

// Get the first tile in the UltraTilePanel
UltraTile tile = this.ultraTilePanel1.Tiles[ 0 ];

// If the first tile is not in the top-left corner of the UltraTilePanel, 
// reposition it to the top-left corner but prevent it from animating to the new position.
if ( tile.PositionInNormalMode != new Point( 0, 0 ) )
	tile.SetPositionInNormalMode( new Point( 0, 0 ), false );
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also