Starting in December, we will archive content from the community that is 10 years and older. This FAQ provides more information.
Hi I want to copy some entities from xref and paste same place.
(command "ncopy" pause pause "0,0" "0,0")
So I tired to pause the command until selection in over.
But select multiple entities, it doesn't work... Please help me
Solved! Go to Solution.
Solved by ВeekeeCZ. Go to Solution.
Not so easy to do. Possibly like this
(while (setq e (cadr (nentsel))) (command "ncopy" e "" "" ""))
But is it really necessary? I mean, how difficult is it to hit enter a couple of times.
Anyway, just a few threads lower @pbejse posted a nice example of code how this could be done without the need to fight with ncopy. HERE
(vl-load-com) (defun c:demo (/ obj tmp) (while (setq obj (nentselp "\nSelect object to copy " ) ;_ end of nentselp ) (progn (setq tmp (entmakex (entget (car obj)))) (vla-transformby (vlax-ename->vla-object tmp) (vlax-tmatrix (caddr obj)) ) (Vla-put-layer (vlax-ename->vla-object (entlast)) (getvar 'clayer)) ) ) )
Can't find what you're looking for? Ask the community or share your knowledge.