I've tried via Dictionaries. I've used sometimes simply '(dictremove (namedobjdict) "ACAD_SCALELIST")' and file size decreased quite a lot. But, I've gone a little bit further, and I've tried this now:
I'd be extremely careful about simply erasing the scales dictionary or any one scale from that. And you will keep on seeing them in the scales list because ACad tries to fix this possible crash situation of having no scales to display.
You need at least one scale left in the DWG. And you actually shouldn't delete scales which has been applied to something - that tends to crash acad. Erasing all scales' dictionaries do not test for scales being applied before deleting them. Anyhow thus use the Reset option in the scalelistedit command - that's a lot safer. Otherwise you'll need to step through everything in the DWG to see which scales can be erased.
Irneb, thank you very much for your advices!
My problems with scales came from a DWG file I recieved from a partner, used as a XREF in a project, in which I detected 6832 different scales (I suppose inherited from other drawings). Every drawing with that XREF attached took about 3 minutes to open ( :realmad: !!!). After I detected the problem, I just deleted the dictionary (the way I've posted), and saved... and it worked: default scales list were re-built as the file was opened without any other problem, 300kb saved in HD and few seconds to open drawings (sometimes, I go breathless, I swear :doa:).
Just
another curiosity 'to whom it may concern': I've used "scalelistedit" (NOT "-scalelistedit") against those 6832 scales, and it appears an error message saying "Matrix index out of range"...
Of course, "-scalelistedit", option "Reset", works properly.
Regards.