Private col1, col2, col3 As B4XTableColumn 'in globals. You can also use an array of cols
B4XTable1.AddColumn("ID", B4XTable1.COLUMN_TYPE_NUMBERS)
B4XTable1.AddColumn("Name", B4XTable1.COLUMN_TYPE_TEXT)
B4XTable1.AddColumn("Street", B4XTable1.COLUMN_TYPE_TEXT)
col1 = B4XTable1.GetColumn("ID")
col2 = B4XTable1.GetColumn("Name")
col3 = B4XTable1.GetColumn("Street")
Private Sub Button1_Click
B4XTable1.VisibleColumns.RemoveAt(B4XTable1.VisibleColumns.IndexOf(col3))
B4XTable1.VisibleColumns.InsertAt(1, col3) '2nd col position 'switch street and name cols order
B4XTable1.Refresh
End Sub