Jump to content

Recommended Posts

Posted

Sometimes there are blocks with contruction lines (xlines) inside them on my drawings. How can I find out on which block the lines are in? I can't select that block by clicking the xline, it doesn't activate. I want to remove those lines but can't refedit the block since I don't know where they belong...

I'm using acad 2004 and 2005 Mechanical.

  • 11 years later...
Posted

I created several blocks within a large file and noticed xlines all over the place. These couldn't be selected nor deleted. Realizing it was part of one of the many blocks, I methodically started selecting blocks where those xlines would highlight as well (can begin with window select mode and drill down). One of the blocks had an xline in it somehow. Using Block Edit I could remove that xline. Hope this helps others. It was a bear in my file for a while.o:)

Posted

Try this:

(defun c:rxl (/ b d l lo nl x)
 ;; RJP - 04.30.2018
 ;; Deletes xlines within block definitions
 (vlax-for a (vla-get-blocks (vla-get-activedocument (vlax-get-acad-object)))
   (if	(= 0 (vlax-get a 'islayout))
     (vlax-for	b a
(if (and (vlax-write-enabled-p b) (= "AcDbXline" (vla-get-objectname b)))
  (vl-catch-all-apply 'vla-delete (list b))
)
     )
   )
 )
 (princ)
)(vl-load-com)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...