SSGET Anonymous Blocks

SSGET Anonymous Blocks

john.uhden
Mentor Mentor
3,189 Views
6 Replies
Message 1 of 7

SSGET Anonymous Blocks

john.uhden
Mentor
Mentor

I ran into something illogical trying to ssget anonymous (unnamed) blocks.

 

You can entmake anonymous blocks.  Just use the name "*U" and AutoCAD will add a numeric end to the name, as in "*U65."

 

One would think that you could select them with (ssget "X" '((0 . "INSERT")(2 . "*U*"))), just like...

Command: (wcmatch "*U*" "*U*") T

 

But NO.  You must precede the first asterisk with a reverse quote ` for the filter to work, as in (ssget "X" '((0 . "INSERT")(2 . "`*U*"))).

 

I mean, once you know that, if you can remember it, then fine.  But it's still illogical to me.

 

BTW, years ago I thought that anonymous blocks could not contain attributes.  Maybe that was true in R11 or something, but yes they can contain attributes.

John F. Uhden

Accepted solutions (1)
3,190 Views
6 Replies
Replies (6)
Message 2 of 7

cadffm
Consultant
Consultant

Every Table, Array, Dimension or dynamic Block are displayed through anonyme Inserts,

that Acad internal Blocks like anonyme Layer and more, not created for Useraccess.

 

And Attributes, no problem (But of course: R11 is pre CADffm-Adesk time)

 

You´re right:  once you know that, if you can remember it, then fine.

 

F1 - About Wild-Card Patterns in Selection Set Filter Lists (AutoLISP)

Sebastian

0 Likes
Message 3 of 7

Ranjit_Singh
Advisor
Advisor

Release 11 added wildcard support to ssget function

ssget_R11.gif

2006 brought along dynamic blocks and I guess now they needed some way of distinguishing between * as part of the name of block vs wildcard.

0 Likes
Message 4 of 7

cadffm
Consultant
Consultant

It came not late with dynamic Blocks.

2004 Help attachment and R14(German)

 

 

 

 

Sebastian

0 Likes
Message 5 of 7

john.uhden
Mentor
Mentor

To quote your help file excerpt, "The wild-card patterns recognized by ssget are the same as those recognized by the wcmatch function."

 

But it is not the same.  (wmatch "*U*" "*U*") returns T.  There is no need for a reverse quote.

 

Yes, I read the following sentence and if those are the rules, then fine.  I have run into situations requiring literal interpretation before, and the reverse quote is often required.  Enough, I'm over it.

 

BTW, I managed to create an elock-violation in that MTJOIN thing.  I'll figure it out.

John F. Uhden

0 Likes
Message 6 of 7

cadffm
Consultant
Consultant
Accepted solution

oups, my attachment lost in Space

 

 

(elock-violation - if you want help, send a message)

Sebastian

0 Likes
Message 7 of 7

john.uhden
Mentor
Mentor

You had better keep that platzhaltermonster in your pants.  You certainly don't want it filterbustering all over everyone.  :]

John F. Uhden

0 Likes