PDA

View Full Version : selection set filters


chuck
11-03-2004, 04:01 PM
I would like to create a selection set of Radial only dimensions. How do I
go about this. The return value for radial dimensions assoc 100 is (100 .
"AcDbEntity") not the (100 . "AcDbRadialDimension") association I require.
I've tried to cdr through the entity list by using a conditional loop (while
(/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq entlist (cdr
entlist)))) thinking that I could use ssadd here but the assoc (100 .
"AcDbRadialDimension") appears to not be equal to (cons 100
"AcDbRadialDimension") for some reason. Even if I use (cdr(car entlist)) it
does not equal "AcDbRadialDimension" and the condition is never satisfied.
Is there something I'm missing?

Jeff
11-03-2004, 04:21 PM
In your filter list, filter on the logical bitwise AND of code 70 for
4......the following will get ALL Radial Dimensions in the drawing:

(setq ss (ssget "x" '((0 . "DIMENSION")(-4 . "&")(70 . 4))))

--
Jeff
check out www.cadvault.com
"chuck" <chuck@nospam.wo> wrote in message
news:Lieid.2730$14.733@read1.cgocable.net...I would like to create a selection set of Radial only dimensions. How do I go about this. The return value for radial dimensions assoc 100 is (100 . "AcDbEntity") not the (100 . "AcDbRadialDimension") association I require. I've tried to cdr through the entity list by using a conditional loop (while (/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq entlist (cdr entlist)))) thinking that I could use ssadd here but the assoc (100 . "AcDbRadialDimension") appears to not be equal to (cons 100 "AcDbRadialDimension") for some reason. Even if I use (cdr(car entlist)) it does not equal "AcDbRadialDimension" and the condition is never satisfied. Is there something I'm missing?

chuck
11-03-2004, 08:45 PM
are there similar functions for diametric and angular dimensions?

"Jeff" <miff@sonic451.net> wrote in message
news:pCeid.3354$_3.36172@typhoon.sonic.net... In your filter list, filter on the logical bitwise AND of code 70 for 4......the following will get ALL Radial Dimensions in the drawing: (setq ss (ssget "x" '((0 . "DIMENSION")(-4 . "&")(70 . 4)))) -- Jeff check out www.cadvault.com "chuck" <chuck@nospam.wo> wrote in message news:Lieid.2730$14.733@read1.cgocable.net...I would like to create a selection set of Radial only dimensions. How do
I go about this. The return value for radial dimensions assoc 100 is (100
.. "AcDbEntity") not the (100 . "AcDbRadialDimension") association I
require. I've tried to cdr through the entity list by using a conditional loop (while (/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq entlist (cdr entlist)))) thinking that I could use ssadd here but the assoc (100 . "AcDbRadialDimension") appears to not be equal to (cons 100 "AcDbRadialDimension") for some reason. Even if I use (cdr(car entlist)) it does not equal "AcDbRadialDimension" and the condition is never
satisfied. Is there something I'm missing?

Jeff
11-03-2004, 09:51 PM
Yes, look into the DXF Reference Manual for the Dimension Entities. See what
the values are for the different type dimensions under the 70 group code.
From memory: 0 is Linear, 1 is Aligned, 2 is 'forget', 4 is Radial, 8 is
'forget' and 16 is 'forget'......hmmm only remember 50%, not good. Oh well,
that's why we have manuals ;-) ,but I don't have one available right now and
the wife wants to watch a movie......

--
Jeff
check out www.cadvault.com
"chuck" <chuck@nospam.wo> wrote in message
news:%siid.2582$hp3.388100@read2.cgocable.net... are there similar functions for diametric and angular dimensions? "Jeff" <miff@sonic451.net> wrote in message news:pCeid.3354$_3.36172@typhoon.sonic.net... In your filter list, filter on the logical bitwise AND of code 70 for 4......the following will get ALL Radial Dimensions in the drawing: (setq ss (ssget "x" '((0 . "DIMENSION")(-4 . "&")(70 . 4)))) -- Jeff check out www.cadvault.com "chuck" <chuck@nospam.wo> wrote in message news:Lieid.2730$14.733@read1.cgocable.net...I would like to create a selection set of Radial only dimensions. How do I go about this. The return value for radial dimensions assoc 100 is (100 . "AcDbEntity") not the (100 . "AcDbRadialDimension") association I require. I've tried to cdr through the entity list by using a conditional loop (while (/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq entlist (cdr entlist)))) thinking that I could use ssadd here but the assoc (100 . "AcDbRadialDimension") appears to not be equal to (cons 100 "AcDbRadialDimension") for some reason. Even if I use (cdr(car entlist)) it does not equal "AcDbRadialDimension" and the condition is never satisfied. Is there something I'm missing?

Jeff
11-03-2004, 09:57 PM
OK, so my memory is horrible tonight......here's the description of the 70
Group code:

Dimension type.
Values 0-6 are integer values that represent the dimension type. Values 32,
64, and 128 are bit values, which are added to the integer values (value 32
is always set in R13 and later releases).
0 = Rotated, horizontal, or vertical; 1 = Aligned;
2 = Angular; 3 = Diameter; 4 = Radius;
5 = Angular 3 point; 6 = Ordinate;
32 = Indicates that the block reference (group code 2) is referenced by this
dimension only.
64 = Ordinate type. This is a bit value (bit 7) used only with integer value
6. If set, ordinate is X-type; if not set, ordinate is Y-type.
128 = This is a bit value (bit 8) added to the other group 70 values if the
dimension text has been positioned at a user-defined location rather than at
the default location

You will have to play around a bit to get the results you need, since I got
lucky with the radial in that it used an Integer that could have been a
bitwise number........will toy with this tomorrow if you haven't figured it
out yet.

--
Jeff
check out www.cadvault.com
"Jeff" <miff@sonic451.net> wrote in message
news:8rjid.3454$_3.36729@typhoon.sonic.net... Yes, look into the DXF Reference Manual for the Dimension Entities. See what the values are for the different type dimensions under the 70 group code. From memory: 0 is Linear, 1 is Aligned, 2 is 'forget', 4 is Radial, 8 is 'forget' and 16 is 'forget'......hmmm only remember 50%, not good. Oh well, that's why we have manuals ;-) ,but I don't have one available right now and the wife wants to watch a movie...... -- Jeff check out www.cadvault.com "chuck" <chuck@nospam.wo> wrote in message news:%siid.2582$hp3.388100@read2.cgocable.net... are there similar functions for diametric and angular dimensions? "Jeff" <miff@sonic451.net> wrote in message news:pCeid.3354$_3.36172@typhoon.sonic.net... In your filter list, filter on the logical bitwise AND of code 70 for 4......the following will get ALL Radial Dimensions in the drawing: (setq ss (ssget "x" '((0 . "DIMENSION")(-4 . "&")(70 . 4)))) -- Jeff check out www.cadvault.com "chuck" <chuck@nospam.wo> wrote in message news:Lieid.2730$14.733@read1.cgocable.net... >I would like to create a selection set of Radial only dimensions. How >do I > go about this. The return value for radial dimensions assoc 100 is > (100 . > "AcDbEntity") not the (100 . "AcDbRadialDimension") association I require. > I've tried to cdr through the entity list by using a conditional loop > (while > (/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq > entlist > (cdr > entlist)))) thinking that I could use ssadd here but the assoc (100 . > "AcDbRadialDimension") appears to not be equal to (cons 100 > "AcDbRadialDimension") for some reason. Even if I use (cdr(car > entlist)) > it > does not equal "AcDbRadialDimension" and the condition is never satisfied. > Is there something I'm missing? > >

chuck
11-04-2004, 09:57 PM
Many thanks Jeff. you've been a great help. Where do you learn all this
stuff anyway? I've been studying this for hours without much luck. I've been
trying to teach myself autolisp, and so far, so good. One thing I have come
to discover though, is that the more you learn the more you realize you know
nothing. Thanks again.

"Jeff" <miff@sonic451.net> wrote in message
news:Hxjid.3455$_3.36781@typhoon.sonic.net... OK, so my memory is horrible tonight......here's the description of the 70 Group code: Dimension type. Values 0-6 are integer values that represent the dimension type. Values
32, 64, and 128 are bit values, which are added to the integer values (value
32 is always set in R13 and later releases). 0 = Rotated, horizontal, or vertical; 1 = Aligned; 2 = Angular; 3 = Diameter; 4 = Radius; 5 = Angular 3 point; 6 = Ordinate; 32 = Indicates that the block reference (group code 2) is referenced by
this dimension only. 64 = Ordinate type. This is a bit value (bit 7) used only with integer
value 6. If set, ordinate is X-type; if not set, ordinate is Y-type. 128 = This is a bit value (bit 8) added to the other group 70 values if
the dimension text has been positioned at a user-defined location rather than
at the default location You will have to play around a bit to get the results you need, since I
got lucky with the radial in that it used an Integer that could have been a bitwise number........will toy with this tomorrow if you haven't figured
it out yet. -- Jeff check out www.cadvault.com "Jeff" <miff@sonic451.net> wrote in message news:8rjid.3454$_3.36729@typhoon.sonic.net... Yes, look into the DXF Reference Manual for the Dimension Entities. See what the values are for the different type dimensions under the 70 group code. From memory: 0 is Linear, 1 is Aligned, 2 is 'forget', 4 is Radial, 8 is 'forget' and 16 is 'forget'......hmmm only remember 50%, not good. Oh well, that's why we have manuals ;-) ,but I don't have one available
right now and the wife wants to watch a movie...... -- Jeff check out www.cadvault.com "chuck" <chuck@nospam.wo> wrote in message news:%siid.2582$hp3.388100@read2.cgocable.net... are there similar functions for diametric and angular dimensions? "Jeff" <miff@sonic451.net> wrote in message news:pCeid.3354$_3.36172@typhoon.sonic.net...> In your filter list, filter on the logical bitwise AND of code 70 for> 4......the following will get ALL Radial Dimensions in the drawing:>> (setq ss (ssget "x" '((0 . "DIMENSION")(-4 . "&")(70 . 4))))>> --> Jeff> check out www.cadvault.com> "chuck" <chuck@nospam.wo> wrote in message> news:Lieid.2730$14.733@read1.cgocable.net...> >I would like to create a selection set of Radial only dimensions. How> >do I> > go about this. The return value for radial dimensions assoc 100 is> > (100 .> > "AcDbEntity") not the (100 . "AcDbRadialDimension") association I require.> > I've tried to cdr through the entity list by using a conditional
loop> > (while> > (/= (car entlist) (cons 100 "AcDbRadialDimension"))(progn (setq> > entlist> > (cdr> > entlist)))) thinking that I could use ssadd here but the assoc (100
..> > "AcDbRadialDimension") appears to not be equal to (cons 100> > "AcDbRadialDimension") for some reason. Even if I use (cdr(car> > entlist))> > it> > does not equal "AcDbRadialDimension" and the condition is never satisfied.> > Is there something I'm missing?> >> >>>

Michael Bulatovich
11-05-2004, 05:21 AM
In life as in LISP....<princ>

"chuck" <chuck@nospam.wo> wrote in message
news:MCEid.3042$14.296@read1.cgocable.net... the more you learn the more you realize you know nothing.

Jeff
11-05-2004, 12:11 PM
"chuck" <chuck@nospam.wo> wrote in message
news:MCEid.3042$14.296@read1.cgocable.net... Many thanks Jeff. you've been a great help. Where do you learn all this stuff anyway? I've been studying this for hours without much luck. I've been trying to teach myself autolisp, and so far, so good. One thing I have come to discover though, is that the more you learn the more you realize you know nothing. Thanks again.

You're welcome Chuck!
As far as learning, I just did what you are now doing.....lots of trial &
error....reading the help, newsgroups and forums....spending more spare time
on the computer than I care to admit.

I couldn't agree more on the "don't know nothin'" part. I am still
constantly learning from others' work.

Good Luck,
Jeff


MyLounge.com Site Map
Forum: Cars, Cell Phone, Database, Games, Home Improvement, IT, Music, School, Sports, Web Design, Web Server, Weight Loss

The MyLounge.com forum is intended for informational use only and should not be relied upon and is not a substitute for any advice. The information contained on MyLounge.com are opinions and suggestions of members and is not a representation of the opinions of MyLounge.com. MyLounge.com does not warrant or vouch for the accuracy, completeness or usefulness of any postings or the qualifications of any person responding. Please consult a expert or seek the services of an attorney in your area for more accuracy on your specific situation. Please note that our forums also serve as mirrors to Usenet newsgroups. Many posts you see on our forums are made by newsgroup users who may not be members of MyLounge.com Term of Service