Column.Sort (Word)

Sorts the specified table column.

If you want to sort paragraphs within a table cell, include only the paragraphs and not the end-of-cell mark; if you include the end-of-cell mark in a selection or range and then attempt to sort the paragraphs, Word displays a message stating that it found no valid records to sort.

Sort (ExcludeHeader, SortFieldType, SortOrder, CaseSensitive, BidiSort, IgnoreThe, IgnoreKashida, IgnoreDiacritics, IgnoreHe, LanguageID)


ActiveDocument.Range.Columns(1).Sort

Arguments

Optional arguments

The following arguments are optional

ExcludeHeader (Boolean) - True to exclude the first row or paragraph header from the sort operation. The default value is False.

SortFieldType (WdSortFieldType) - The sort type for the column. Can be one of the WdSortFieldType constants.


Possible values are

wdSortFieldAlphanumeric Alphanumeric order.
wdSortFieldDate Date order.
wdSortFieldJapanJIS Japanese JIS order.
wdSortFieldKoreaKS Korean KS order.
wdSortFieldNumeric Numeric order.
wdSortFieldStroke Stroke order.
wdSortFieldSyllable Syllable order.

SortOrder (WdSortOrder) - The sorting order to use for the column. Can be one WdSortOrder constant.

Possible return values are wdSortOrderAscending - Ascending order. Default, wdSortOrderDescending - Descending order.

CaseSensitive (Boolean) - True to sort with case sensitivity. The default value is False.

BidiSort (Boolean) - True to sort based on right-to-left language rules. This argument may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.

IgnoreThe (Boolean) - True to ignore the Arabic character alef lam when sorting right-to-left language text. This argument may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.

IgnoreKashida (Boolean) - True to ignore kashidas when sorting right-to-left language text. This argument may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.

IgnoreDiacritics (Boolean) - True to ignore bidirectional control characters when sorting right-to-left language text. This argument may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.

IgnoreHe (Boolean) - True to ignore the Hebrew character he when sorting right-to-left language text. This argument may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.

LanguageID (WdLanguageID) - Specifies the sorting language. Can be one of the WdLanguageID constants.

Here you can find possible values for WdLanguageID