MMS Posted August 26, 2011 Share Posted August 26, 2011 I have problem with my code especially for create list multiple selection. I choose more than one object but the result still have one list. _$ GETDYNPROPS <Selection set: 1b> 0 nil 4 _$ Could someone give explanation where's wrong with my code. ;mencari data (defun getdynprops (obj / v) (vl-remove-if 'null (mapcar '(lambda (x) (if (setq v (vlax-variant-value (vla-get-value x))) (cons (vla-get-propertyname x) v))) (vlax-safearray->list (vlax-variant-value (vla-getdynamicblockproperties obj))))) ) ;-------------- (vl-load-com) (setq ss (ssget )) (setq i 0) ;(setq ssd (ssadd)) (setq LiSS '()) (repeat (sslength ss) (setq i i) (setq ename (ssname ss i)) (setq vevo (vlax-ename->vla-object ename)) (setq LVevo (cdr(car(getdynprops vevo)))) (setq LiVevo (cons LVevo LiSS)) (setq i (1+ i)) );repeat Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted August 26, 2011 Share Posted August 26, 2011 Change: (setq LiVevo (cons LVevo LiSS)) To: (setq LiSS (cons LVevo LiSS)) Then check the value of the 'LiSS' variable. Make sure you localise your variables though!! Quote Link to comment Share on other sites More sharing options...
MMS Posted August 26, 2011 Author Share Posted August 26, 2011 Change: (setq LiVevo (cons LVevo LiSS)) To: (setq LiSS (cons LVevo LiSS)) Then check the value of the 'LiSS' variable. Make sure you localise your variables though!! Hi Lee, Thanks for your explanation. Done 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.