unreferenced blocks

Discussion in 'AutoCAD' started by mhawkes, Oct 13, 2004.

  1. mhawkes

    mhawkes Guest

    Does anybody know of a method for getting rid of unreferenced blocks. I have a couple that won't go away no matter what I do. I've erased everything, exploded all the AEC objects, removed all MV blocks, purged everything in sight, double checked to make sure they aren't part of a dimensions style, etc. I guess what I'm looking for is a routine (VBA, lisp, etc.) that will allow me to remove all references to a block (by name) from the file. I've looked over the discussion groups and haven't found anything so far. Unfortunately, I have many, many files with this problem, so a solution a little more elegant than the wblock method would be a definite advantage.

    Thanks in advance
    Marcus
     
    mhawkes, Oct 13, 2004
    #1
  2. Are the blocks referenced in a dictionary?

    --
    Autodesk Discussion Group Facilitator



    have a couple that won't go away no matter what I do. I've erased
    everything, exploded all the AEC objects, removed all MV blocks, purged
    everything in sight, double checked to make sure they aren't part of a
    dimensions style, etc. I guess what I'm looking for is a routine (VBA,
    lisp, etc.) that will allow me to remove all references to a block (by name)
    from the file. I've looked over the discussion groups and haven't found
    anything so far. Unfortunately, I have many, many files with this problem,
    so a solution a little more elegant than the wblock method would be a
    definite advantage.
     
    Jason Piercey, Oct 13, 2004
    #2
  3. mhawkes

    Doug Broad Guest

    What version of ADT are you running?
    Have you tried ExportToAutoCAD?


    that won't go away no matter what I do. I've erased everything, exploded all the AEC
    objects, removed all MV blocks, purged everything in sight, double checked to make sure
    they aren't part of a dimensions style, etc. I guess what I'm looking for is a routine
    (VBA, lisp, etc.) that will allow me to remove all references to a block (by name) from
    the file. I've looked over the discussion groups and haven't found anything so far.
    Unfortunately, I have many, many files with this problem, so a solution a little more
    elegant than the wblock method would be a definite advantage.
     
    Doug Broad, Oct 13, 2004
    #3
  4. mhawkes

    mataeux Guest

    post one file, we may find a solution


    have a couple that won't go away no matter what I do. I've erased
    everything, exploded all the AEC objects, removed all MV blocks, purged
    everything in sight, double checked to make sure they aren't part of a
    dimensions style, etc. I guess what I'm looking for is a routine (VBA,
    lisp, etc.) that will allow me to remove all references to a block (by name)
    from the file. I've looked over the discussion groups and haven't found
    anything so far. Unfortunately, I have many, many files with this problem,
    so a solution a little more elegant than the wblock method would be a
    definite advantage.
     
    mataeux, Oct 13, 2004
    #4
  5. mhawkes

    Xolo Guest

    Have you tried using superpurge?

    Xolo
     
    Xolo, Oct 13, 2004
    #5
  6. mhawkes

    Don Butler Guest

    Maybe see if this turns up anything...

    ;;;(brefs BLOCKNAME)
    ;;;Returns list of ENAMES of references

    (defun brefs (blk / bnam)
    (if (setq bnam (tblobjname "block" blk))
    (mapcar 'cdr
    (vl-remove-if-not
    '(lambda (x) (= (car x) 331))
    (entget (dxf 330 (entget bnam)))
    )
    )
    (alert "No references found!")
    )
    )

    Don
     
    Don Butler, Oct 13, 2004
    #6
  7. Maybe they are null blocks (blocks with no entity).

    Try to redefine the blocks and see if they come out.

    Or: erase all remove <select all visible objects> return.

    Take a look at the number of entities selected and removed.

    --

    Marc'Antonio Alessi
    http://xoomer.virgilio.it/alessi
    (strcat "NOT a " (substr (ver) 8 4) " guru.")

    --
     
    Marc'Antonio Alessi, Oct 14, 2004
    #7
  8. Hi mhawkes,

    Sounds like you are using ADT or something similar. Not sure what version
    you have.

    To purge these MV Blocks use either the AECSTYLEMANAGER command or the
    pulldown menu Desktop > Style Manager... and highlight the file or the style
    you want to purge and hit the Purge Styles button at the top. (Not sure
    where the menu is in 2005 yet). Then if you have to you should be able to
    purge them out using the purge command.

    Hope this helps.

    Arnold Williams
     
    Arnold Williams, Oct 14, 2004
    #8
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.