Here, I've created LISP for you, but what I've found while writing it is that "cdorder.lsp" from Express Tools had lack, so I've incorporated it inside lisp in it's entirety with my mod. - I am using A2014, so bear me if you have other one correct, but I doubt... Also incorporated (plintav) sub and (overkill-MR) sub made by me... Before you start routine make sure CDORDER is correct - my lisp is working only with DXF 62 code of colors so only ACII colors - not true colors... Upon finishing routine it will UNDO changes made while processing and if you haven't done anything meanwhile - you just opened DWG, it may ask to UNDO everything to beginning of DWG session - just answer "Y"...
I hope it will help you...
Regards, M.R.