symoin Posted May 12, 2010 Posted May 12, 2010 Hello!! I have a lots of survey points that i have to join with a common point then i have to join those points with an arc contineously to form a circle. Is there any lisp or code to ease the work. look at the attached sample drawing. Course-2.dwg Quote
alanjt Posted May 14, 2010 Posted May 14, 2010 This should get you started... (defun c:Test (/ ss pt) (princ "\nSelect points: ") (if (and (setq ss (ssget '((0 . "POINT")))) (setq pt (getpoint "\nSpecify center point to connect points: ")) ) ((lambda (i p) (while (setq e (ssname ss (setq i (1+ i)))) (entmake (list '(0 . "LINE") '(100 . "AcDbEntity") '(100 . "AcDbLine") (assoc 10 (entget e)) (cons 11 p) ) ) ) ) -1 (trans pt 1 0) ) ) (princ) ) Quote
symoin Posted May 15, 2010 Author Posted May 15, 2010 This should get you started... (defun c:Test (/ ss pt) (princ "\nSelect points: ") (if (and (setq ss (ssget '((0 . "POINT")))) (setq pt (getpoint "\nSpecify center point to connect points: ")) ) ((lambda (i p) (while (setq e (ssname ss (setq i (1+ i)))) (entmake (list '(0 . "LINE") '(100 . "AcDbEntity") '(100 . "AcDbLine") (assoc 10 (entget e)) (cons 11 p) ) ) ) ) -1 (trans pt 1 0) ) ) (princ) ) Thanks, your code works fine for the first part of my requirement. Also hope something for my second part. I use the command PLINE and select the first point then for the nextpoint option I use the sub command Arc by typing A and then the option for second by typing S and the select the other point as end point and then type the S and so on. Here is the text from the command history pasted. Specify start point: Current line-width is 0.0000 Specify next point or [Arc/Halfwidth/Length/Undo/Width]: a Specify endpoint of arc or [Angle/CEnter/Direction/Halfwidth/Line/Radius/Second pt/Undo/Width]: s Specify second point on arc: Specify end point of arc: Specify endpoint of arc or [Angle/CEnter/CLose/Direction/Halfwidth/Line/Radius/Second pt/Undo/Width]: s Specify second point on arc: Specify end point of arc: Specify endpoint of arc or [Angle/CEnter/CLose/Direction/Halfwidth/Line/Radius/Second pt/Undo/Width]: s Specify second point on arc: Specify end point of arc: Specify endpoint of arc or [Angle/CEnter/CLose/Direction/Halfwidth/Line/Radius/Second pt/Undo/Width]: thanks Quote
alanjt Posted May 15, 2010 Posted May 15, 2010 Thanks,your code works fine for the first part of my requirement. Also hope something for my second part. I use the command PLINE and select the first point then for the nextpoint option I use the sub command Arc by typing A and then the option for second by typing S and the select the other point as end point and then type the S and so on. This should get you started... I understand your second request and as I said, this should get you started. Have you given it a shot yourself? Quote
eldon Posted May 16, 2010 Posted May 16, 2010 In the other branch of your multiple posting (see how easy it is to confuse and break up lines of thought), I was uneasy about the geometrical validity of your method. The way you do it, you create 16 individual arcs (when you do it properly), that are not tangential. Is that what the powers that be want? The picture shows what the effect is (exaggerated) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.