TheSwamp
Code Red => AutoLISP (Vanilla / Visual) => Topic started by: Vikram on January 21, 2020, 03:25:35 AM
-
I have a drawing in which I'm not able to join the lines. When I zoom it I see there is tiny gap between the lines but I'm not able to stretch it too. How do I join the lines?
Reference drawing is attached
-
1 - Off the SNAP
2 - use (command "_.PEDIT" "_M" ...) with precision distance
3 - :)
-
I tired that not working :-(
The end points of the lines are not joined.See the drawing
-
Comando: _PEDIT
Selezionare polilinea o [Multiplo]: _m
Selezionare oggetti: Specificare angolo opposto: trovato(i) 2
Selezionare oggetti:
Digitare un'opzione [CHiudi/Apri/Unisci/Larghezza/ADatta/Spline/Rettifica/Tipolinea gen./Inverti/ANnulla]: _j
Tipo unione = Estendi
Digitare distanza approssimazione o [Tipo unione] <0.1000>:
2 segmenti aggiunti alla polilinea
Digitare un'opzione [CHiudi/Apri/Unisci/Larghezza/ADatta/Spline/Rettifica/Tipolinea gen./Inverti/ANnulla]:
-
I tired that not working :-(
The end points of the lines are not joined.See the drawing
I do not know why, but it can no be selected more than one entity .
as per the logfile you can sse it.
[ AutoCAD - Tue Jan 21 09:43:35 2020 ]----------------------------------------
Command: LOGFILEPATH
Enter new value for LOGFILEPATH, or . for none <"h:\">: *Cancel*
Command: *Cancel*
Command: LOGFILEON
Command:
Command:
Command: _pedit
Select polyline or [Multiple]:
Select polyline or [Multiple]:
Enter an option [Close/Join/Width/Edit vertex/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: J
Select objects: 1 found
Select objects:
0 segments added to polyline
Enter an option [Close/Join/Width/Edit vertex/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: J
Select objects: *Cancel*
Enter an option [Close/Join/Width/Edit vertex/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: *Cancel*
Command:
Command:
Command: _pedit
Select polyline or [Multiple]: m
Select objects: 1 found
Select objects: 1 found, 1 total
Select objects: 1 found, 1 total
Select objects: 1 found, 1 total
Select objects: 1 found, 1 total
Select objects:
Enter an option [Close/Open/Join/Width/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: J
Join Type = Extend
Enter fuzz distance or [Jointype] <0.1000>:
0 segments added to polyline
Enter an option [Close/Open/Join/Width/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: C
Enter an option [Close/Open/Join/Width/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: *Cancel*
Command:
Command: _erase
Select objects: 1 found
Select objects:
Command: *Cancel*
Command: *Cancel*
Command: _.undo Current settings: Auto = On, Control = All, Combine = Yes, Layer = Yes
Enter the number of operations to undo or [Auto/Control/BEgin/End/Mark/Back] <1>: 1 ERASE GROUP
Command: *Cancel*
Command: *Cancel*
Command: _.undo Current settings: Auto = On, Control = All, Combine = Yes, Layer = Yes
Enter the number of operations to undo or [Auto/Control/BEgin/End/Mark/Back] <1>: 1 Polyline Edit GROUP
Crossing Lasso Press Spacebar to cycle options
Command: Specify opposite corner or [Fence/WPolygon/CPolygon]:
Command: *Cancel*
Command: *Cancel*
Command:
Command:
Command: _pedit
Select polyline or [Multiple]: m
Select objects: all
3 found
Select objects:
Enter an option [Close/Open/Join/Width/Fit/Spline/Decurve/Ltype gen/Reverse/Undo]: *Cancel*
Command: *Cancel*
Command: MPEDIT
Initializing...
Select objects: 1 found
Select objects: 1 found, 1 total
Select objects: 1 found, 1 total
Select objects: *Cancel*
Command: *Cancel*
Command:
Automatic save to C:\Program Files (x86)\AutoCAD 2008\Support\join seperated lines _1_27415_4764.sv$ ...
Command:
Command:
Command:
Command: _copy
Select objects: Specify opposite corner: 1 found
Select objects: 1 found, 1 total
Select objects: 1 found, 1 total
Select objects: *Cancel*
Command: LOGFILEOFF
-
@Vikram:
The issue may be that you are using IntelliCAD. Please consider adding this to your signature. It would prevent a lot of confusion.
-
After saved as acad 2018 , and using "all" a selection set , it join with a fuzze= 0.1 .
-
I tired that not working :-(
The end points of the lines are not joined.See the drawing
I do not know why, but it can no be selected more than one entity .
...
1 - Off the SNAP
-
Thanks for they help!
roy_43 I wish I could use Autocad but my company prefered Intellicad. I'm facing lot of problems due to no proper forum of Intellicad.
-
Please consider specifying that you are using Intellicad either in your forum signature as Roy as noted, or as part of your question when starting a new thread, as many solutions offered are not generally compatible across all CAD platforms and it will avoid a lot of unnecessary debugging by users attempting to help you with a solution which isn't compatible on your platform.
-
Try this codes, he can meet your needs
https://drive.google.com/file/d/1W1qIRgkptZgRJBkiI2Jvx4690-P8-_Uj/view?usp=sharing
(defun c:test (/ e ba bm bx ss kk pp)
(setq os (getvar "osmode"))
(setvar "osmode" 0)
(setq ss (ssget))
(setq i 0 )
(repeat (sslength ss)
(setq en (ssname ss i))
(setq e (cdr (assoc 0 (entget en))))
(if (or (= e "ARC") (= e "LINE"))
(setq bm (cons en bm))
)
(setq bx (cons en bx))
(setq i (+ i 1))
)
(foreach x bm
(vl-cmdf "_.pedit" "_m" x "" "_y" "")
(setq ba (cons (entlast) ba))
)
(setq kk (append bx ba ))
(setq pp (ssadd))
(mapcar '(lambda (x) (setq pp (ssadd x pp) )) kk)
(vl-cmdf "_.pedit" "_m" pp "" "_j" "3" "")
(setvar "osmode" os)
)