Jump to content

Trim Lines Even If Line Is Inside A Block


kArThIcK hAcKeR

Recommended Posts

Hi Guys,:)

 

i have some drawings with blocks in them, (CAD file has been Attached below):fishing:

Sample Block.dwg

 

sometimes, i need to trim the lines inside the blocks. (Screenshot below):bloodshot:

Sample Block.jpg

 

As Trim Doesn't Work on Blocks, i had to explode or burst the blocks and then trim the lines. :wacko:

 

But i don't want to burst or explode the blocks, because the blocks have properties.:rtfm:

 

Is there any lisp routine that can fulfill my requirement?

 

or, does anybody know a way to trim the lines inside the blocks without exploding?:unsure:

 

PS:

i know that use "edit block in place" and then use the "trim" command, but using this method 155 times can be irritating.:itsover:

Link to comment
Share on other sites

I would make one block, already trimmed, with the correct properties. Then copy it around your dwg 155 times. Search for "nested trim" if that wont work for you !

Link to comment
Share on other sites

I would make one block, already trimmed, with the correct properties. Then copy it around your dwg 155 times.

Actually these blocks look similar, but the dimensions and the properties of the blocks vary each time, so i can't copy the blocks around,:)

 

Search for "nested trim" if that wont work for you !

BTRIM, trims to objects nested in blocks and external references. It doesn't trim the block itself so this command doesn't help me,

Link to comment
Share on other sites

Well you could always add a stretch parameter or two into your block (that is trimmed), therefor allowing you to copy one block around the dwg, and then go modify it slightly for each instance based on the dimensions?

 

 

Hopefully someone will come along and offer you a lisp solution

Link to comment
Share on other sites

Well you could always add a stretch parameter or two into your block (that is trimmed), therefor allowing you to copy one block around the dwg, and then go modify it slightly for each instance based on the dimensions?

No, Actually most of these drawings are outsourced or it is from a 3D Modelling Software. So Making Dynamic Blocks is out of the options.:unsure:

 

Hopefully someone will come along and offer you a lisp solution

I tried to make a lisp on my own, The lisp opens the block in "refedit" mode and then trim the line8)

(defun c:TRB()
(command "-refedit" PAUSE "Ok" "All" "Yes")
(command "TRIM" "" PAUSE "" )
(command "_.refclose" "S")
(command "regen") ;regenerate
)
(princ)
(princ "\n:::Type \"TRB\" to trim blocks:::")
(princ)

 

The Only Problem with the above code is that i have to click twice,:oops:

Link to comment
Share on other sites

Autocad really needs to make it so you can trim around a block. it would it so much easier. I don't see the benefit of not being able to.

Link to comment
Share on other sites

This may help or not search for cookiecutter.lsp it wil require say for above pick 4 pts.

 

I already tried that LISP Bigal, :)

The Only Problem in the "Cookiecutter" is that it "BURST's" The Block, if the block gets burst the properties wont be available, :ouch:

 

 

Any Other Ideas?

Link to comment
Share on other sites

Because you know the shape of the block create a new block that is the correct shape from a pline explode once then try wipeout picking pline.

 

the block shape is sometimes the same, sometimes it is not the same, so making a wipeout will be hard.:unsure:

 

Please see the below attachment for details, :geek:

SAMPLE2.dwg

 

U can See That the shape of the block changes every time, if i had to use the wipeout method, it wouldn't be so productive,:o

 

Can U give me some more ideas on that LISP that i had posted? (coz, i find the lisp method easy to use)

Link to comment
Share on other sites

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...