Elektryk Posted February 19, 2010 Share Posted February 19, 2010 dwg file included is there any way to transform the object on the right to the object on the left by using Autolisp? like when i load app it will ask me which object, which way to do the offset ( inside or outside ( in this case 1/8 and to the outside ) ) and after the selections it will redraw the object on the right so it looks like the one on the left. i have 142 objects similar to that one , and it would take me a while to do them. could anyone help creating the lsp file? thanks template.dwg Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 ??? anyone? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 19, 2010 Share Posted February 19, 2010 Give us a chance... I'll have a look, see what's what. Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 finally.... ok i'll wait Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 19, 2010 Share Posted February 19, 2010 is there any way to transform the object on the right to the object on the leftby using Autolisp? and afet [sic] the selections it will redraw the object on the left so it looks like the one on the right. Which is it? Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 Which is it? haaaaaaaaa? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 19, 2010 Share Posted February 19, 2010 haaaaaaaaa? Your original post seems to contradict itself, that is, if I am reading it correctly. Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 Your original post seems to contradict itself, that is, if I am reading it correctly. meaning? Quote Link to comment Share on other sites More sharing options...
stevesfr Posted February 19, 2010 Share Posted February 19, 2010 Your original post seems to contradict itself, that is, if I am reading it correctly. Lee is correct !! read the OP again !! Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 Which is it? im sorry........ other way around... sorry... I'll fix that... Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 done.. i'm soooo sorry... Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 ................? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 19, 2010 Share Posted February 19, 2010 Its quite a tedious LISP to create - perhaps someone here wants to spend some time on it. Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 19, 2010 Author Share Posted February 19, 2010 Its quite a tedious LISP to create - perhaps someone here wants to spend some time on it. is it possible? Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 20, 2010 Share Posted February 20, 2010 is it possible? Yes, I would think so, but its not too interesting to create Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 20, 2010 Author Share Posted February 20, 2010 so it is hard isnt it?... Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 20, 2010 Share Posted February 20, 2010 so it is hard isnt it?... No, it seems to just required the creation of a polyline with certain measurements. Quote Link to comment Share on other sites More sharing options...
Elektryk Posted February 20, 2010 Author Share Posted February 20, 2010 still looking..... Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted February 20, 2010 Share Posted February 20, 2010 still looking..... As I said, perhaps other members on here want to donate their time to working on a LISP for you. Quote Link to comment Share on other sites More sharing options...
paulmcz Posted February 21, 2010 Share Posted February 21, 2010 Here is the deal: here you have the first half of the program (transforming selected geometry to the object on the left = "outside") and you finish it for the transformation the other way around. When you get stuck, then ask here. (defun c:tio (/ aa osn) (initget "I O") (setq aa (getkword "\n Select option -> Inside [i], Outside [O]: ") osn (getvar "osmode") ) (cond ((= aa "I") (i)) ((= aa "O") (o)) (t nil) ) (princ) ) (defun o (/ ip p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 p11 p12 p13 p14) (setvar "osmode" 4) (setq ipt (getpoint "\n Insert new objects: ")) (setvar "osmode" 0) (princ "\n Select objects to erase: ") (setq ss (ssget) ip (polar ipt pi 7.75) p1 (polar ip 0 1.75) p2 (polar p1 (* pi 0.5) 6.0) p3 (polar p1 0 12.0) p4 (polar ip 0 15.5) p5 (polar p4 (* pi 0.5) 8.49331856) p6 (polar p5 (* pi 0.5) 0.5) p7 (polar p6 pi 0.5) p8 (polar p6 pi 15.0) p9 (polar p5 pi 15.5) p10 (polar ip 0 0.5) ; p11 (polar p10 (* pi 0.5) 2.25) p12 (polar p11 (* pi 0.5) 4.0) p13 (polar p11 0 14.5) p14 (polar p12 0 14.5) ) (setvar "osmode" 0) (command "pline" ip p1 "a" "d" p2 p3 "l" p4 p5 "a" p7 "l" p8 "a" p9 "l" "c" "") (command "circle" p11 0.125) (setq e1 (entlast)) (command "copy" e1 "" "m" p11 p12 p13 p14 "") (command "erase" ss "") (setvar "osmode" osn) (princ) ) (defun i () (alert "The <INSIDE> option of the program is to be written by Elektryk" ) ) Quote Link to comment Share on other sites More sharing options...
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.