|Page (1) of 1 - 01/16/02||email article||print page|
AutoLISP TipSSGET Function
Let's make a test. First, set the limits of the drawing from 0.0,0.0 till 420,297. After doing that give the drawing a ZOOM ALL.
Now let's draw a circle outside of the visible viewport. The centerpoint of the circle is at 1000,500. The radius of the circle is 10.
Let's try to make a selections set with the circle. The following statements can be used:
(setq ss (ssget "w" (list 900 400) (list 1100 600)))
(setq ss (ssget "c" (list 900 400) (list 1100 600)))
Nothing is found.
Bring the circle into the viewport. Do a ZOOM EXTENTS and PAN the circle somewhere in the middle of the visible viewport.
Now a selection set is created using the above mentioned statements.
AutoCAD! AutoCAD! This I haven't found in the documentation that comes with AutoCAD. I found it out the hard way.
What can you do about it? Make sure that the entities to be selected are in the visible viewport. Give a ZOOM EXTENTS before using the SSGET function.
Jos van Doorn.is an AutoCAD specialist, AutoLISP programmer and editor of the ACAD newsletter. To subscribe to the FREE newsletter send e-mail to: mailto:email@example.com
He has written six AutoCAD books. Interested in the books. Let him know. Send an e-mail to: mailto:firstname.lastname@example.org
Related Keywords:AutoCAD, AutoLSP
Source:Digital Media Online. All Rights Reserved