Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/14/2023 in all areas

  1. (defun c:spl2pl ( / ss i ent ss3 ss2 obj cpcount j ) (princ "\n Select spline to convert to pline : ") (setq ss (ssget '((0 . "SPLINE")))) (setq i 0) (setq ss3 (ssadd)) (repeat (sslength ss) (setq ent (ssname ss i)) (command "_explode" ent "") (setq ss2 (ssget "_P")) (setq j 0) (repeat (sslength ss2) (setq ent2 (ssname ss2 j)) (setq obj (vlax-ename->vla-object ent2)) (setq cpcount (vlax-get-property obj 'Numberofcontrolpoints)) (command "_SPLINEDIT" ent2 "_P" cpcount "") (ssadd (entlast) ss3) (setq j (+ j 1)) ) (setq i (+ i 1)) ) (if (> (sslength ss3) 1) (progn (command "_pedit" "_M" ss3 "" "J" "0" "") ) (progn (command "_pedit" ss3 "") ) ) (princ) ) 1. Roughly, i think this is not you want 2. use wmf zoom > object wmfout wmfin explode it you get 2dpolyline automatically, > scale it and convert 3. save as drawing or wblock spline to oldest .dxf version as you can, ex) R12 and then reopen it. it changed to 3dpolyline explode it and then mpedit join them all
    2 points
  2. Another method: ;; Returns the middle of two points (defun mid-pt (p1 p2) (polar p1 (angle p1 p2) (/ (distance p1 p2) 2.) ) )
    1 point
×
×
  • Create New...