colReorder.move()

Since: ColReorder 1.4.0

Programmatically move columns. Please note - this property requires the ColReorder extension for DataTables.

Description

This method provides the ability to programmatically change the order of one column at a time (while colReorder.order() will set the order of all columns together).

Type

function colReorder.move( from, to [, drop [, invalidate ] ] )

Description:

Programmatically reorder columns

Parameters:
Returns:

Unmodified API instance.

Example

Move the first column in the table to the second position:

var table = $('#example').DataTable( {
	colReorder: true
} );

table.colReorder.move( 0, 1 );