[]
You can allow the user to drag and move rows or columns. Set the AllowRowMove property to allow the user to move rows and the AllowColumnMove property to allow the user to move columns. If you wish to allow the user to move multiple rows or columns, also set the AllowRowMoveMultiple or AllowColumnMoveMultiple property.
You can hide the drag band while moving the row or column with the ShowDragBandOnMoving property.
For the user to move rows or columns, they left click on the header of the row or column to move and drag the header back or forth over the header area and release the mouse over the header of the desired destination (for multiple rows or columns, select them first). The row or column that is being moved is shown in a transparent clone attached to the pointer, as shown in this figure, where the fourth column is being moved to the left.
To relocate a row, use the SheetView.SheetView method; to remove multiple rows at a time, use the SheetView.RemoveRows method. To relocate a column, use the SheetView.MoveColumn method; to remove multiple columns at a time, use the SheetView.RemoveColumns method. Alternatively, you can use the Move method of the DefaultSheetAxisModel class.
You can use the GetColumnFromTag method to find columns based on their Tag property, which you can set programmatically to whatever you want. You can do the same with the Tag method for rows.
You can also delete multiple rows with the Remove method of the Rows class which represents a range of rows. Similarly, you can also remove multiple columns with the Remove method of the Columns class. For example,
fpSpread1.Sheets[0].Columns[1, 5].Remove();
FpSpread1.Sheets(0).Columns(1, 5).Remove()
At design time, in the Properties window, select the Spread component.
In the Misc category, select the AllowRowMove or the AllowColumnMove property.
Click the drop-down arrow to display the choices and select the value (True or False). Repeat this for each property.
Set the AllowRowMove or AllowColumnMove property for the FpSpread component.
This example allows the user to move columns or rows.
fpSpread1.AllowRowMove = true;
fpSpread1.AllowColumnMove = true;
fpSpread1.AllowRowMove = True
fpSpread1.AllowColumnMove = True
Select Spread from the drop-down combo list located on the top right side of the Designer.
From the Misc section, select True or False for AllowRowMove or AllowColumnMove.
From the File menu, select Save and Exit to save the changes.
Customizing the Number of Rows or Columns
Showing or Hiding a Row or Column
Setting the Row Height or Column Width
Setting Fixed (Frozen) Rows or Columns