Author Topic: non-graphical non-native objects  (Read 4621 times)

0 Members and 1 Guest are viewing this topic.

Lee Mac

  • Seagull
  • Posts: 12905
  • London, England
Re: non-graphical non-native objects
« Reply #15 on: July 09, 2009, 02:34:44 PM »
This client of yours seems a bit stringent... I'd tell him what he can do with his dictionary standards...   :-P

CAB

  • Global Moderator
  • Seagull
  • Posts: 10401
Re: non-graphical non-native objects
« Reply #16 on: July 09, 2009, 03:09:46 PM »
Something to try, will empty the dictionaries.
Minimal testing.
Code: [Select]
(defun c:DicSTYLEClean ( / dics dic dicName tmpname)
  (vl-load-com)
  (setq dics (vla-get-dictionaries
               (vla-get-activedocument (vlax-get-acad-object))
             )
  )
  (foreach dicname '("ACAD_MLEADERSTYLE"        "ACAD_MLINESTYLE"
                     "ACAD_PLOTSTYLENAME"       "ACAD_TABLESTYLE"
                     "ACAD_SCALELIST"           "ACAD_VISUALSTYLE"
                    )
    (if (or
          (vl-catch-all-error-p
            (setq dic (vl-catch-all-apply 'vla-item (list dics dicname))))
          (null dic))
      (prompt (strcat "\n+++  Dictionary " dicname " does not exist."))
      (progn
        (prompt (strcat "\nProcessing Dictionary " dicname " ."))
        (vlax-for item dic
          (setq TmpName (vla-getname dic item))
          (if (or (member (strcase TmpName) '("DEFAULT" "STANDARD"))
                  (vl-catch-all-error-p (vl-catch-all-apply 'vla-delete (list item)))
              )
            (prompt (strcat "\n  Dictionary entry " TmpName " can not be deleted."))
            (prompt (strcat "\n  ***  Removed " TmpName " from dictionary."))
          )
        )
      )
    )
  )
  (princ)
)
I've reached the age where the happy hour is a nap. (°¿°)
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

V-Man

  • Bull Frog
  • Posts: 343
  • I exist therefore I am! Finally Retired!
Re: non-graphical non-native objects
« Reply #17 on: July 09, 2009, 03:28:00 PM »

Quote
This client of yours seems a bit stringent... I'd tell him what he can do with his dictionary standards

It's kind of hard to tell the GOV what to do.
AutoCAD 9 - 2023, AutoCADMap 2008 - 2010, Revit 2012 - 2022, Autocad Civil 3D 2023

Daniel J. Ellis

  • Swamp Rat
  • Posts: 811
Re: non-graphical non-native objects
« Reply #18 on: July 09, 2009, 04:56:45 PM »
Have you tried copying everything from the origin back to the origin of a new drawing?

dJE
===
dJE

V-Man

  • Bull Frog
  • Posts: 343
  • I exist therefore I am! Finally Retired!
Re: non-graphical non-native objects
« Reply #19 on: July 09, 2009, 05:12:42 PM »

Quote
Have you tried copying everything from the origin back to the origin of a new drawing?

Yes, that is the first thing I tried.
AutoCAD 9 - 2023, AutoCADMap 2008 - 2010, Revit 2012 - 2022, Autocad Civil 3D 2023