CAD_Question Posted October 4, 2019 Share Posted October 4, 2019 HI Everyone, I'm currently making a library of custom blocks that will be inserted into a custom toolbar. I have tried to create a macro to insert, rotate and trim around the block, but am having trouble with the trim portion of the command. if someone could edit the macro below to allow for the trim command to work it would be greatly appreciated. ^C^C_insert;"Flanged Swing Check Valve";\;;;Rotate;last;; Quote Link to comment Share on other sites More sharing options...
steven-g Posted October 4, 2019 Share Posted October 4, 2019 You have one too many semi-colons after inserting the block, does this work for you? ^C^C_insert;"Flanged Swing Check Valve";\;;Rotate;last;;\\Trim;last;; This should finish with the prompt to select objects to trim and let you start picking objects. Why not use the Rotation option when you are inserting the block (unless the rotattion isn't based at the insert point)? that would just save a bit of code. Quote Link to comment Share on other sites More sharing options...
CAD_Question Posted October 4, 2019 Author Share Posted October 4, 2019 I tried this, but there wasn't a prompt to trim? Quote Link to comment Share on other sites More sharing options...
CAD_Question Posted October 4, 2019 Author Share Posted October 4, 2019 It seems like the old macro is still linked to the block somehow? I went to the long string editor and changed the macro to insert and trim only (just to test the macro) and it will insert the block, then prompt for a rotation at the insertion point and finally end the macro. Any thoughts on when might be going wrong? Quote Link to comment Share on other sites More sharing options...
steven-g Posted October 4, 2019 Share Posted October 4, 2019 You should be seeing this, depending on whether you use dynamic input or just the command line, if not then can you post a screenshot of what you see on the command line. Quote Link to comment Share on other sites More sharing options...
steven-g Posted October 4, 2019 Share Posted October 4, 2019 Where do you have the macro, I just run mine from a toolpalette Quote Link to comment Share on other sites More sharing options...
CAD_Question Posted October 4, 2019 Author Share Posted October 4, 2019 (edited) I run mine withing the CUI. Here is the command line. Edited October 4, 2019 by CAD_Question Quote Link to comment Share on other sites More sharing options...
steven-g Posted October 4, 2019 Share Posted October 4, 2019 Looks like your system may well require that extra semi-colon during the insert part, try adding that back in. I created a test block and have it set to use uniform scaling which is probably why I don't need 3 semi-colons. Quote Link to comment Share on other sites More sharing options...
CAD_Question Posted October 4, 2019 Author Share Posted October 4, 2019 That worked! Thanks for all the help on this! Quote Link to comment Share on other sites More sharing options...
steven-g Posted October 4, 2019 Share Posted October 4, 2019 Your welcome, sorry about the mix up. Quote Link to comment Share on other sites More sharing options...
BIGAL Posted October 5, 2019 Share Posted October 5, 2019 (edited) You can use lisp in macros so it could be rewritten, it makes the number of ; and \ etc a bit clearer to follow. The other thing to look at is the block default settings looking at 2020 its slightly different now depending on what is ticked on a insert can be name and pt only. This is probably why Steven-g had 1 less ; Actually got down to block name only. Block inserted at 0,0,0 scale 1 1 1 rotation 0. Edited October 5, 2019 by BIGAL Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.