'Declaration Public Property AllowColMoving As AllowColMoving
public AllowColMoving AllowColMoving {get; set;}
The AllowColMoving property determines how columns can be moved by the user in the band or the grid controlled by the specified override. Depending on the setting of AllowColMoving, users can move columns anywhere within the band, only within a group, or not at all. In order for the user to be able to move columns, column headers must be visible. If AllowColMoving is set to allow column moving within the band or the group, column headers become draggable, and are used to re-arrange the order of the columns via the mouse.
This property does not affect the ability of users to swap columns using the column swapping dropdown found in the column header (controlled by the AllowColSwapping property) or on the ability of the user to move groups within the grid (controlled by the AllowGroupMoving property).
Imports Infragistics.Shared Imports Infragistics.Win Imports Infragistics.Win.UltraWinGrid Private Sub Button2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button2.Click ' Disallow users to move columns. Properties set on DisplayLayout's Override ' effect the whole grid. Me.UltraGrid1.DisplayLayout.Override.AllowColMoving = AllowColMoving.WithinBand ' You can override above grid-wide setting for a particular band by setting the ' property in question to a non-default value in the Override object of that ' band. Me.UltraGrid1.DisplayLayout.Bands(0).Override.AllowColMoving = AllowColMoving.NotAllowed End Sub
using Infragistics.Shared; using Infragistics.Win; using Infragistics.Win.UltraWinGrid; using System.Diagnostics; private void button2_Click(object sender, System.EventArgs e) { // Disallow users to move columns. Properties set on DisplayLayout's Override // effect the whole grid. this.ultraGrid1.DisplayLayout.Override.AllowColMoving = AllowColMoving.WithinBand; // You can override above grid-wide setting for a particular band by setting the // property in question to a non-default value in the Override object of that // band. this.ultraGrid1.DisplayLayout.Bands[0].Override.AllowColMoving = AllowColMoving.NotAllowed; }
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