acad_strlsort (AutoLISP)

Sorts a list of strings in alphabetical order

Supported Platforms: Windows and Mac OS

Signature

(acad_strlsort list)
list

Type: List

The list of strings to be sorted.

Return Values

Type: List or nil

The list in alphabetical order. If the list is invalid or if there is not enough memory to do the sort, acad_strlsort returns nil.

Examples

Sort a list of abbreviated month names:

(setq mos '("Jan" "Feb" "Mar" "Apr" "May" "Jun" "Jul" "Aug" "Sep" "Oct" "Nov" "Dec"))
("Jan" "Feb" "Mar" "Apr" "May" "Jun" "Jul" "Aug" "Sep" "Oct" "Nov" "Dec")

(acad_strlsort mos)
("Apr" "Aug" "Dec" "Feb" "Jan" "Jul" "Jun" "Mar" "May" "Nov" "Oct" "Sep")