add_key method

add_key

Adds sorted column index and sort order.

def add_key(self, key, order):
    ...
ParameterTypeDescription
keyintThe sorted column index(absolute position, column A is 0, B is 1, …)
orderSortOrderThe sort order

add_key

Adds sorted column index and sort order with custom sort list.

def add_key(self, key, order, custom_list):
    ...
ParameterTypeDescription
keyintThe sorted column index(absolute position, column A is 0, B is 1, …)
orderSortOrderThe sort order.
custom_liststrThe custom sort list.

add_key

Adds sorted column index and sort order with custom sort list.

def add_key(self, key, order, custom_list):
    ...
ParameterTypeDescription
keyintThe sorted column index(absolute position, column A is 0, B is 1, …)
orderSortOrderThe sort order.
custom_listlistThe custom sort list.

add_key

Adds sorted column index and sort order with custom sort list.

def add_key(self, key, type, order, custom_list):
    ...
ParameterTypeDescription
keyintThe sorted column index(absolute position, column A is 0, B is 1, …)
typeSortOnTypeThe sorted value type.
orderSortOrderThe sort order.
custom_listanyThe custom sort list.

Remarks

If type is SortOnType.CellColor or SortOnType.FontColor, the customList is Color.

See Also