satishrajdev Posted May 10, 2013 Posted May 10, 2013 how to get x & y coords from given angle and distance. i need a code for that if Distance=80, Angle=45.....i want to draw line with first point A(0,0) to the next point B from given distance and angle. I know i can use @distance Kindly reply Thanks a lot:) Quote
Tharwat Posted May 10, 2013 Posted May 10, 2013 Try this . (setq b (polar '(0. 0. 0.) (/ pi 4.) 80.)) Quote
BIGAL Posted May 10, 2013 Posted May 10, 2013 A bit more (defun dtr (a) (* pi (/ a 180.0)) ) (setq pt1 (getpoint "\nPick point")) (setq ang (dtr (getreal "\nEnter angle"))) (setq dist (getreal "\nEnter distance")) (Setq pt2 (polar pt1 ang dist)) (princ pt2) Quote
satishrajdev Posted May 10, 2013 Author Posted May 10, 2013 Thanks a lot guys........ its working great for me:thumbsup: Quote
satishrajdev Posted May 10, 2013 Author Posted May 10, 2013 i want to ask 1 more thing while drawing leader from entmakex what is code for arrow head type, i want to give user arrow head by block Quote
pBe Posted May 10, 2013 Posted May 10, 2013 hmmmn. never tried creating a leader using entmakex before. Hows about showing us your code satishrajdev Quote
satishrajdev Posted May 10, 2013 Author Posted May 10, 2013 (entmakex (list '(0 . "LEADER") '(100 . "AcDbEntity") '(100 . "AcDbLeader") '(410 . "Model") (cons 10 (trans B 1 0)) (cons 10 (trans A 1 0)) '(71 . 1) '(72 . 0) '(73 . 3) '(74 . 0) '(75 . 0) '(76 . 2) ) ) I want to change arrow head to "user Arrow" and specify a blockname for that Quote
pBe Posted May 10, 2013 Posted May 10, 2013 My guess is it will be too complicated compared to AddLeader Method. But i'm pretty sure it can be done. Quote
satishrajdev Posted May 10, 2013 Author Posted May 10, 2013 Ok. Then any suggestions from your side, or any else way to do this???? 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.