error bad ssget list

error bad ssget list

dlbsurveysuk
Collaborator Collaborator
265 Views
1 Reply
Message 1 of 2

error bad ssget list

dlbsurveysuk
Collaborator
Collaborator

What's wrong with this? I'm trying to select all blocks "P_Z" that are colour BLUE

 

(setq PZB (ssget "_A" '((2 . "P_Z")(cons 62 5))))

 

It gives error bad ssget list.

 

I'm having real trouble getting any SSGET selections with multiple parameters to work.

 

Thanks

0 Likes
Accepted solutions (1)
266 Views
1 Reply
Reply (1)
Message 2 of 2

ВeekeeCZ
Consultant
Consultant
Accepted solution

(setq PZB (ssget "_A" (list '(2 . "P_Z") (cons 62 5))))

Once you use cons, all the upper can't be just quoted - needs to be evaluated.

 

But in this case of yours, you don't really need cons.

(setq PZB (ssget "_A" '((2 . "P_Z")(62 . 5))))