_$ (setq pt1 '(0.0 0.0 0.0))
(setq pt2 '(5.0 5.0 0.0))
(setq pt3 '(4.0 1.0 0.0))
(setq pt4 '(2.0 6.0 0.0))
(setq ss (ssget "_F" (list pt2 pt3 pt4)))
(setq en (ssname ss 0))
(setq ent (entget en))
(setq entname (cdr (assoc 0 ent)))
(setq entpos (cdr (assoc 10 ent)))
(0.0 0.0 0.0)
(5.0 5.0 0.0)
(4.0 1.0 0.0)
(2.0 6.0 0.0)
<Selection set: c7>
<Entity name: 1484230>
((-1 . <Entity name: 1484230>) (0 . "POINT") (330 . <Entity name: 14840f8>)
(5 . "5E") (100 . "AcDbEntity") (67 . 0) (410 . "Model") (8 . "0") (100 .
"AcDbPoint") (10 3.0 3.5 0.0) (210 0.0 0.0 1.0) (50 . 0.0))
"POINT"
(3.0 3.5 0.0)
Regards,
Jan
"Adesu" <mte...@yuasabattery.co.id> schreef in bericht
news:41bd277f_3@newsprd01...
(setq pt1 '(0.0 0.0 0.0))
(setq pt2 '(5.0 5.0 0.0))
(setq pt3 '(4.0 1.0 0.0))
(setq pt4 '(2.0 6.0 0.0))
(setq ss (ssget ":E" (list pt2 pt3 pt4)))
(setq en (ssname ss 0))
(setq ent (entget en))
(setq entname (cdr (assoc 0 ent)))
(setq entpos (cdr (assoc 10 ent)))
(0.0 0.0 0.0)
(5.0 5.0 0.0)
(4.0 1.0 0.0)
(2.0 6.0 0.0)
; error: bad SSGET list
Jan van de Poel <erg...@nergens.nl> wrote in message
news:41bda8fe_1@newsprd01...
--
Bill DeShawn
bdes...@nospamsterling.net
http://my.sterling.net~bdeshawn
"Adesu" <mte...@yuasabattery.co.id> wrote in message
news:41bd277f_3@newsprd01...
This should work.
regards,
Jan
"Adesu" <mte...@yuasabattery.co.id> schreef in bericht
news:41be3128_2@newsprd01...
_$ (setq pt1 (getpoint "Enter first corner: "))
(setq pt3 (getpoint "Enter second corner: "))
(setq pt2 (list(car pt3)(cadr pt1)))
(setq pt4 (list (car pt1)(cadr pt3)))
(setq ss (ssget ":E" (list pt2 pt3 pt4)))
(0.0 0.0 0.0)
(5.0 5.0 0.0)
(5.0 0.0)
(0.0 5.0)
; error: bad SSGET list
_$ (setq pt1 (getpoint "Enter first corner: "))
(setq pt3 (getpoint "Enter second corner: "))
(setq pt2 (list(car pt3)(cadr pt1)))
(setq pt4 (list (car pt1)(cadr pt3)))
(setq ss (ssget ":E" (list pt2 pt3 pt4)))
(5.0 5.0 0.0)
(0.0 0.0 0.0)
(0.0 5.0)
(5.0 0.0)
; error: bad SSGET list
_$
Jan van de Poel <erg...@nergens.nl> wrote in message
news:41be97ed$1_3@newsprd01...
This code works for me:
(setq pt1 (getpoint "Enter first corner: "))
(setq pt3 (getpoint pt1 "Enter second corner: ")) ; added pt1 to get the
'rubber band'
(setq pt2 (list(car pt3)(cadr pt1)))
(setq pt4 (list (car pt1)(cadr pt3)))
(setq ss (ssget "F" (list pt2 pt3 pt4))) ; F for fence, not E
(setq en (ssname ss 0))
(setq ent (entget en))
(setq entname (cdr (assoc 0 ent)))
(setq entpos (cdr (assoc 10 ent)))
What are you trying to achieve with this program?
Regards,
Jan
The :E option limits you to a pick box.
If you want to select entities at a given point use:
(setq ss (ssget "c" pt1 pt1))
;---;
If you want to add fuzz to the selection point.
;---;
(defun a_little_square (p tol)
(list (mapcar '+ p (list tol tol))(mapcar '- p (list tol tol))
)
)
(setq ss (ssget "c" (car box)(cadr box))
HTH
Bill
_$ (setq pt1 '(0.0 0.0 0.0))
(setq pt2 '(5.0 0.0 0.0))
(setq pt3 '(5.0 5.0 0.0))
(setq pt4 '(0.0 5.0 0.0))
(setq ss (ssget ":E"))
(setq en (ssname ss 0))
(setq ent (entget en))
(setq entname (cdr (assoc 0 ent)))
(setq entpos (cdr (assoc 10 ent)))
(0.0 0.0 0.0)
(5.0 0.0 0.0)
(5.0 5.0 0.0)
(0.0 5.0 0.0)
<Selection set: 2>
<Entity name: 1481d88>
((-1 . <Entity name: 1481d88>) (0 . "CIRCLE") (330 . <Entity name: 1481cf8>)
(5 . "49") (100 . "AcDbEntity") (67 . 0) (410 . "Model") (8 . "0") (100 .
"AcDbCircle") (10 5.0 5.0 0.0) (40 . 1.0) (210 0.0 0.0 1.0))
"CIRCLE"
(5.0 5.0 0.0)
_$
CAB2k <nos...@address.withheld> wrote in message
news:28868968.110302938...@jiveforum2.autodesk.com...
If you want just one pick add :S
(ssget ":E:S")
Saves you from hitting enter after one pick.
Don't know about the VLC. I never use it.
Bill
For more info on ssget filters go here
http://www.smadsen.com/
Look for the tutorial on ssget
And come visit us at the http://theswamp.org/phpBB2/
"Adesu" <mte...@yuasabattery.co.id> wrote in message
news:41beaa37_2@newsprd01...
--
Bill DeShawn
bdes...@nospamsterling.net
http://my.sterling.net~bdeshawn
"Jan van de Poel" <erg...@nergens.nl> wrote in message
news:41beca29_3@newsprd01...
"Bill DeShawn" <bdes...@nospamsterling.net> wrote in message
news:41c128e8_1@newsprd01...
(ssget "+.:E:S")
Whats the "+." for?
Was given to me on this forum but I can't remember now.
Was it Tony Tanzillo or Michael Puckett....mmmm.
IIRC: They said they found it in some developers guide (not lisp).
Bill
--
R. Robert Bell
"BillZ" <nos...@address.withheld> wrote in message
news:12349639.110320370...@jiveforum2.autodesk.com...
i must've missed that.
Bill
--
Bill DeShawn
bdes...@nospamsterling.net
http://my.sterling.net~bdeshawn
"BillZ" <nos...@address.withheld> wrote in message
news:14265639.110311556...@jiveforum1.autodesk.com...