Community
Civil 3D Forum
Welcome to Autodesk’s Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Finding Line Types in Blocks?

5 REPLIES 5
Reply
Message 1 of 6
cattjake
2409 Views, 5 Replies

Finding Line Types in Blocks?

Hello,

 

So... Long story short, we got cad files from an older survey done for a realtor. Everything was in pretty bad shape, with blocks everywhere. Since then the drawings have been cleaned up significantly. But I am having issues with two line types referencing a .shx file we dont have. The line types will not come out in a purge or manual delete efforts. I tried to do a filter by linetype but it continues to feed back 0 selected. I am wondering if the line types are used in a block definition that isn't drawn anywhere on the screen.

 

Is there a way to determine what linetypes are used in what blocks?

 

Ultimatly once the lines that use the two linetypes are locted they will be changed to a different one and purged out of the drawing.

 

Any help is greatly appreciated.

 

Thanks,

 

5 REPLIES 5
Message 2 of 6
thepworth
in reply to: cattjake

I'm not sure how you could list all objects/lines within a block, but you can click on individual entities with "XLIST"

 

Works for blocks & x-ref nested items.

Message 3 of 6
cattjake
in reply to: thepworth

Thanks for the reply,

 

I don't think there are even any blocks drawn with it, just in the defintion so it will not let you remove. So i would have to insert every single block and look at them.

Message 4 of 6
thepworth
in reply to: cattjake

Another thought - check to see if it's included with any of the tools from Terry Dotson - www.dotsoft.com - his library is pretty extensive, but 3rd party (not a bad thing, but if it's not in his "free tools" area, will be at a nominal cost)

Message 5 of 6
Alfred.NESWADBA
in reply to: thepworth

Hi,

 

>> Is there a way to determine what linetypes are used in what blocks?

If you are a little bit familiar with DXF then save your drawing as DXF, open this DXF with an ascii-editor (like NotePad++) and search for your linetype-name.

 

Good luck, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 6 of 6
Jeff_M
in reply to: cattjake

Here's a simple lisp that will scan all the blocks in the drawing and report where the named linetype is used by an object. Note that the specific linetype must be assigned to the object, not via the layer. 

(defun c:findLTusage (/ ltname blocks)
  (vl-load-com)
  (setq ltname (strcase (getstring t "\nEnter name of linetype to search for: ")))
  (setq blocks (vla-get-blocks (vla-get-activedocument (vlax-get-acad-object))))
  (vlax-for blk blocks
    (vlax-for ent blk
      (if (and (vlax-property-available-p ent 'linetype)
	       (eq (strcase (vla-get-linetype ent)) ltname)
	       )
	(progn
	  (princ (strcat "Linetype used in block named: " (vla-get-name blk) ", by object of type: " (vla-get-objectname ent)))
	  )
	)
      )
    )
  (princ)
  )

 

Jeff_M, also a frequent Swamper
EESignature

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report