Author Topic: about Selection Sets making  (Read 1737 times)

0 Members and 1 Guest are viewing this topic.

dussla

  • Bull Frog
  • Posts: 297
about Selection Sets making
« on: November 07, 2007, 08:34:52 PM »
i wonder selection sets making ~

ex) i selected 24 circels
     those selection set name is  " cir"

1.  i would like to copy  cir set(=24 circles)  -> i would like make  other  set  about  cir set(=24 circles)  which   copied   
   how can make it
 


2. i would like to array  cir set
   and i would like to  make selection set about   all set  which  arried  again

3. i copybased cir set (=24 circels)     
   and pastercliped
   without  ssgeting about pastercliped obects , how can i make selection set about
 objects which  pastecliped ?


i will wait good anser
 

Crank

  • Water Moccasin
  • Posts: 1503
Re: about Selection Sets making
« Reply #1 on: November 15, 2007, 01:13:07 PM »
If I understand you right, you want a selectionset of all new created entities. Those entities are added to the database, so you first need to find the last object.
(entlast) doesn't work if the last entity is a block with attributes and polylines also can give some problems. You need to find the true end of the existing database first. This can be done with something like:
Code: [Select]
(defun LASTENT (/ E0 EN)
(setq E0 (entlast))
(while (setq EN (entnext E0))
(setq E0 EN)
)
E0
)
To make a sectionset of all new created entities you can use:
Code: [Select]
(defun newSS (el / ss)
(setq ss (ssadd))
(while (setq el (entnext el))
(ssadd el ss)
)
ss
)

Your program will be something like:
Code: [Select]
(defun c:Test (/ el)
  (setq el (lastent)); This is the true last entity
 
  (command ".copy" pause)

  (setq AddedEnts (newSS el))
  (princ "\nAddedEnts contains the new created entities.")
  (princ)
)
« Last Edit: November 15, 2007, 01:16:15 PM by Crank »
Vault Professional 2023     +     AEC Collection

CAB

  • Global Moderator
  • Seagull
  • Posts: 10401
Re: about Selection Sets making
« Reply #2 on: November 17, 2007, 11:05:38 AM »
I've reached the age where the happy hour is a nap. (°¿°)
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.