• This forum is the machine-generated translation of www.cad3d.it/forum1 - the Italian design community. Several terms are not translated correctly.

select all objects of a layer

  • Thread starter Thread starter zintonio
  • Start date Start date

zintonio

Guest
Hello.
I often have to select many objects belonging to a specific layer to be scaled, rotated, copied, moved etc. to avoid having to select all objects, lines, blocks etc. to zoom and get lost in the sheet and maybe even forget something, there is a lisp or a command to select all objects belonging to a layer?
Thank you.
 
I think you can do it from the express tools.
I still do this:
  • open layer management
  • I'm running the layer that interests me
  • select all layers at the same time
  • congelo all layers in a single stroke
the current layer, that is what interests you, will not freeze.
at this point if you want to select all the layers objects, give the command with the option you (all)
I hope I've been helpful
 
Thank you for the wizzy answer. I have seen the filter is a bit ruddy to use it.. .in the sense that it is not immediate....I have seen that there is also the quick selection that is less rognose....there is something simpler like I put a command and choose an object of any of the layer in question and select all the objects of that layer.
Thank you.
 
for me the best command remains selerapid, if you have the installed express tools you can also use ssx


command: ssx

select object <none>: </none>indigo (*)

enter filter option [Block
name/Color/Entity/Flag/LAyer/LType/Pick/Style/Thickness/Vector]: la

>>enter layer name to add <return remove="" to="">: </return>poplar

current filter: ((8 . "pippo"))
enter filter option [Block
name/Color/Entity/Flag/LAyer/LType/Pick/Style/Thickness/Vector]:
9 found.Now you can launch the command you need, to the object selection request type p (previous).


(*) if you select an object you will select only the homologue objects placed on that layer, then only texts, only lines, etc.
 
I don't know. which version of autocad use? what comes to mind is to use the express tools menu. if you have not installed it you find it in the installation cd. the lisp layiso (if I don't remember badly it is called so) of the express allows to isolate a layer by turning off all others. clearly you will be visible only the objects of the isolated layer. :finger:

Oops... had arrived before gp
 
Um, I was missing out on a lisp list, while gp indicated a pretty perfect solution. . .
 
And yet a better method, according to me, is there.

(defun lsel() (ssget "x" (cons 8 (getvar "clayer")))))

the function returns the selection group of current layer entities.
practically, set the current layer, launch the copy command, instead of selecting writes (lsel).

bye
 
then, effectively as gp says the quick selection is fine and is a great solution. The filter is a little uncomfortable.
the advice of wizzy using layiso is moolto useful and good but then I have to remember all the layers to turn on and off and maybe I take more time x than they are about a 120 layer.
I tried the function of rpor66 but I can't make it work maybe I mistake something in the sense that I create a .lsp file with the lsel function and then I load the lisp and follow the written advice but nothing happens ("unval function") continues the copy function.
 
since the battle is crucified.... :36_6_10: assigns this instruction to a button:

^c^c(command "_select" (ssget "_x" (list (cons 8 (cdr (assoc 8 (entget (car (entsel "select an object on the desired layer...."))))");)");

a selection group is created that you can switch to the next command object selection request by typing p (previous).
But I throw the sponge on the nil of final return, I can't make it disappear.
 
Hi, gp,
I tried to run the function just mail but it comes back <selection 96ff="" set=""> And then nothing... it doesn't select anything.
Am I wrong?</selection>
 
zì, paste from the first ^ to the last ; as macro in a new button, launch it and select an object.

to the next command that launches for the modification of selected objects type p
 
I tried the function of rpor66 but I can't make it work maybe I mistake something in the sense that I create a .lsp file with the lsel function and then I load the lisp and follow the written advice but nothing happens ("unval function") continues the copy function.
write in command:
(load "creagroupselectionlayer.lsp")
make the layer you want to copy.
copy
(lsel)
send (confem selection made)

then continue with the command.

bye
 

Attachments

So, thank you all for having discussed this problem together, whose solution can serve, I think, everyone.

I followed the instructions of gp and I have to say that it works very well, I had misunderstood in the previous message, it performs perfectly what I was willing to do. a button associated with a very useful function :finger:

I also performed the rpor66 instructions and also this works great as that of gp, effectively wrong x that I did not put parentheses to (lsel). :finger:

all in all the two solutions are both fast compared to the quick selection (they save about a 10 seconds to make aperation depends on what command I have to do (copy, wheel, scale etc.)) this multiplied by thousands of times I use these objects save a lot of time.

thanks to all
 
since the battle is crucified.... :36_6_10: assigns this instruction to a button:

^c^c(command "_select" (ssget "_x" (list (cons 8 (cdr (assoc 8 (entget (car (entsel "select an object on the desired layer...."))))");)");

a selection group is created that you can switch to the next command object selection request by typing p (previous).
But I throw the sponge on the nil of final return, I can't make it disappear.
if you check a button:
(ssget "_x" (cons 8 (cdr (assoc 8 (entget (car (entsel "select an object on the desired layer....")))))));

you can use it during the copy command.

bye
 
I would also try to getsel express tools, which works in 2 times:
1- choose the layer by pointing on an object of that layer
2- Send to choose all the objects of that layer (or point to an object to select only that type of object)
 
if you check a button:
(ssget "_x" (cons 8 (cdr (assoc 8 (entget (car (entsel "select an object on the desired layer....")))))));

you can use it during the copy command.

bye
Good roberto, this is la solution. :finger:
 
for joseph,
I used getsel but it doesn't select me, in the sense that when I click on an object it only tells me: 560 objects have been placed in the active selection set.

for gp and rpor66, the solution is right but if I press the button during the copy or move or some other operation, the latter is canceled and I have to remake it by typing p as soon as I appear select objects.
therefore I do not understand the quote of rpor66:

if you check a button:
(ssget "_x" (cons 8 (cdr (assoc 8 (entget (car (entsel "select an object on the desired layer....")))))));

you can use it during the copy command.

bye
 
zinto,
josh solution only selects entities.
Successfully you will give any command (copy, wheel etc) and when it tells you to select objects you will reply "p" (previous)

for the dedicated key solution, when you create the key make sure you have removed from the start of the string the ^c

in fact if you copy the string
(ssget "_x" (cons 8 (cdr (assoc 8 (entget (car))))))))

with the copy of windows (ctrl c) and an acad command (copy moves etc) and at the request select objects, paste on the command line the string (ctrl v), this will be executed without interrupting the command.

check if the command assigned with your icon, contains a ^c string at the beginning of the command string.
I hope I've been clear
 
You were very clear, I didn't understand!...I just did the test!:finger:

you actually have to remove ^c from the macro of the button and then performs perfectly the selection of all objects of a layer during copying or moving and so on.

I was fossilizing on the command without taking into account the "c xchés" I thought they go by default and instead I realized that sometimes you have to ometer them as in this case.

joseph's advice is very similar to the gp starting board....that is to press p while selecting objects.

I therefore agree with gp, saying that the optimal solution is that of rpor66....as very fast.
 

Forum statistics

Threads
44,997
Messages
339,767
Members
4
Latest member
ibt

Members online

No members online now.
Back
Top