Community
bad drawing. Z axis can't to zero.
I use command "FLATTEN" can't reset Z axis to zero. I use LISP ,but it's too.
;;vla ;;(HH:vlaZto0 (ssget)) (defun HH:vlaZto0 (ss / E N OBJ P1 P2) (defun MoveOne (e) (setq obj (vlax-ename->vla-object e)) (vla-move obj p1 p2) (vla-move obj p2 p1) ) (setq p1 (vlax-3d-point '(0 0 0))) (setq p2 (vlax-3d-point '(0 0 1000e99))) (cond ((equal (type ss) 'ENAME) (MoveOne ss)) ((equal (type ss) 'PICKSET) (repeat (setq n (sslength ss)) (MoveOne (ssname ss (setq n (1- n)))) ) ) ) )
;;DXF ;;(XX:LeftPick:LineZto0Ent (car(entsel))) (defun XX:LeftPick:LineZto0Ent (ss) (defun MoveOne (e) (entmod (mapcar '(lambda (X) (cond ((or (equal (car x) 11) (equal (car x) 10)) (list (car x) (cadr x) (caddr x))) (T x) ) ) (entget e) ) ) ) (cond ((equal (type ss) 'ENAME) (MoveOne ss)) ((equal (type ss) 'PICKSET) (repeat (setq n (sslength ss)) (MoveOne (ssname ss (setq n (1- n)))) ) ) ) )
any routine or any tools can solve this problem ?
DWG file in attachments.
You can try attached CHZ20.vlx.
I also attached the result dwg here.
It doesn't work on Region objects though.