I have an existing lisp routine that makes copies of an existing "template" layout one by one using an alphabetized list of layout names. For example, the "template" layout is named "TEMPLATE" and (to keep things simple) the list of names might be "A", "B", "C", etc. The "Template" layout name is assigned to the TBLAYOUT variable, and the desired name of the copy is assigned to a variable named MAP. The code looks like:
(command "layout" "copy" TBLAYOUT MAP)
This works fine, and the new layouts have previously all been arranged together at the bottom of the drawing editor in alphabetical order:
Model/A/B/C/D/E/TEMPLATE
However, beginning with AutoCAD 2019 and now AutoCAD 2024 (we skipped the versions in between) the new layouts do not stay in alphabetical order. Instead, they may be arranged such as:
Model/C/D/E/TEMPLATE/A/B
This is not a big deal if there are a dozen or so layouts, but sometimes we have over a hundred and they can be annoying to put in order. We do use Lee Mac's TabSort routine to fix it, but I'd like to get it right the first time, since the list is already in alphabetical order.
Any ideas why this is happening, and is there a simple solution that I'm overlooking? Thank you.