ziele_o2k Posted December 8, 2017 Share Posted December 8, 2017 (edited) I whant to select dynamic blocks with some conditions: Each block scale has to be grather than 0 X Y and Z scale factor has to be the same for indivdual block I know how to get blocks with condition No.1 inside ssget, but can it be done for second one? Example: Block 1: scale factors X=1 Y=1 Z=1 (select) Block 2: scale factors X=-1 Y=-1 Z=-1 (don' t select) Block 2: scale factors X=2 Y=3 Z=2 (don' t select) Block 3: scale factors X=4 Y=4 Z=4 (select) To get blocks with scale grather than 0 I can use: (ssget (list (cons 0 "INSERT") (cons 410 "Model") ;(cons 2 Anonymous References of dynamic block) (cons -4 "<AND") (cons -4 ">") (cons 41 0) (cons -4 ">") (cons 42 0) (cons -4 ">") (cons 43 0) (cons -4 "AND>") ) ) Can I add condition to function above which will check if 41 42 and 43 codes are equal? Workaround solution can be this one: Workaround solution deleted Edited December 8, 2017 by ziele_o2k Workaround solution was wrong. Quote Link to comment Share on other sites More sharing options...
Roy_043 Posted December 8, 2017 Share Posted December 8, 2017 have you tested your workaround? Quote Link to comment Share on other sites More sharing options...
ziele_o2k Posted December 8, 2017 Author Share Posted December 8, 2017 have you tested your workaround? No there can be some errors - i wrote this as example. Quote Link to comment Share on other sites More sharing options...
Aftertouch Posted December 8, 2017 Share Posted December 8, 2017 Personaly i would use your 'workaround' to filter the selection, since the SSGET can get very confusing. Also, i double it can handle a '=' check for multiple AND variable values... Quote Link to comment Share on other sites More sharing options...
Roy_043 Posted December 8, 2017 Share Posted December 8, 2017 In your workaround you finally filter inserts based on their name and layout. The result can include inserts with faulty scaling factors. Quote Link to comment Share on other sites More sharing options...
ziele_o2k Posted December 8, 2017 Author Share Posted December 8, 2017 In your workaround you finally filter inserts based on their name and layout. The result can include inserts with faulty scaling factors. True, my workaround is wrong, I can write another (in my case it would be great if ssget would work with ename or handle ). Nevertheless this is not my question 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.