Jump to content

Redefining Blocks with a script


Recommended Posts

Posted

I need to redefine a number of Blocks in numerous existing drawings. I have redrawn the Blocks and Wblocked each of them to individual drawings. From within a drawing that requires the redefinitions I run a script to insert the new version eg:

-insert

detector=C:/.../detector.dwg

the command asks for an insertion point - since I do not need to actually insert a copy of the Block, I press ESC at this stage.

I then repeat this with the appropriate script for each of the Blocks to be redefined.

I have tried to create a combined script to redefine all the Blocks in a single operation by inserting ESC between the lines eg:

-insert

detector=C:/.../detector.dwg

ESC

-insert

alarm=C:/.../alarm.dwg

but this doesn't work - the script hangs at the first insertion, asking for the insertion point - pressing ESC simply terminates the script.

Can I get the script to skip the insertion and go on to the next?

Or can I call one script from within another?

Posted

Just insert the block then

Erase last

 

next line in you script

 

not pretty but should work carefull though if redefine required yes etc need the correct number of enters (new line)

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