MUTHUKUMAR1983 Posted May 14, 2023 Posted May 14, 2023 (edited) MAIL4.mp4 (DEFUN C:FLR() (SETQ P1(GETPOINT "\n PICK FIELD LINE START POINT :") P2(GETPOINT P1 "\n PICK FIELD LINE END POINT :") P3(GETPOINT P1 "\n PICK RIGHT SIDE :") AN1(ANGLE P1 P2) ) (COMMAND "UCS" "3" P1 P2 P3 "") (REPEAT 100 (SETQ GS(GETSTRING "\n FIELD LINE NUMBER :") YV(GETREAL "\n ENTER LINE LENGTH VALUE:") ;-15 XV(GETREAL "\n ENTER OFFSET VALUE:") ;56.8 ; FV(*(- YV)1) ;P2(POLAR P1 0 FV) ) (COMMAND "POINT" (LIST XV YV) ) ;(TRANS '(0.0 0.0 1.0) 0 1 T) (ENTMAKE (LIST (CONS 0 "TEXT") (CONS 100 "AcDbEntity") (CONS 100 "AcDbText") (CONS 10 (LIST XV YV)) ; POINT (CONS 40 8) (CONS 7 (GETVAR 'textstyle)) (CONS 8 "Some layer") (CONS 62 1) (CONS 1 GS) ;VALUE (CONS 50 0 ) )) ) ;(PRINT FV) ) MAIL4.mp4 Edited May 14, 2023 by MUTHUKUMAR1983 VIDEO PROBLEM Quote
Steven P Posted May 14, 2023 Posted May 14, 2023 I don't have CAD running today, but a couple of thoughts, For UCS - do you need it changed to this after the LISP ends? you might want to look at resetting it to what it was before. OR don't change the UCS and work out the points using polar coordinates from the UCS you had before and the line angle. You could probably get rid off P3 if you do that and let the user define the direction of right by the order they click on the lines Quote
MUTHUKUMAR1983 Posted May 14, 2023 Author Posted May 14, 2023 30 minutes ago, MUTHUKUMAR1983 said: MAIL4.mp4 912.1 kB · 0 downloads (DEFUN C:FLR() (SETQ P1(GETPOINT "\n PICK FIELD LINE START POINT :") P2(GETPOINT P1 "\n PICK FIELD LINE END POINT :") P3(GETPOINT P1 "\n PICK RIGHT SIDE :") AN1(ANGLE P1 P2) ) (COMMAND "UCS" "3" P1 P2 P3 "") (REPEAT 100 (SETQ GS(GETSTRING "\n FIELD LINE NUMBER :") YV(GETREAL "\n ENTER LINE LENGTH VALUE:") ;-15 XV(GETREAL "\n ENTER OFFSET VALUE:") ;56.8 ; FV(*(- YV)1) ;P2(POLAR P1 0 FV) ) (COMMAND "POINT" (LIST XV YV) ) ;(TRANS '(0.0 0.0 1.0) 0 1 T) (ENTMAKE (LIST (CONS 0 "TEXT") (CONS 100 "AcDbEntity") (CONS 100 "AcDbText") (CONS 10 (LIST XV YV)) ; POINT (CONS 40 8) (CONS 7 (GETVAR 'textstyle)) (CONS 8 "Some layer") (CONS 62 1) (CONS 1 GS) ;VALUE (CONS 50 0 ) )) ) ;(PRINT FV) ) MAIL4.mp4 912.1 kB · 0 downloads MAIL4.mp4 Quote
Tsuky Posted May 14, 2023 Posted May 14, 2023 (entmake) have required alway coordinates in WCS also (CONS 10 (LIST XV YV)) ; POINT is no good (CONS 10 (trans (LIST XV YV) 1 0)) ; POINT must be used 1 Quote
MUTHUKUMAR1983 Posted May 14, 2023 Author Posted May 14, 2023 ITS WORK FINE THANKS 1000 TIME Tsuky 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.