Jump to content

Test ! bad drawing. Z axis can't to zero.


77077

Recommended Posts

I use command "FLATTEN" can't reset Z axis to zero.

I use LISP ,but it's too.

 

[color=#444444][color=#444444];;vla[/color][/color]
[color=#444444][color=#444444];;(HH:vlaZto0 (ssget))[/color]
[color=#444444](defun HH:vlaZto0 (ss / E N OBJ P1 P2)[/color]
[color=#444444]  (defun MoveOne (e)[/color]
[color=#444444]    (setq obj (vlax-ename->vla-object e))[/color]
[color=#444444]    (vla-move obj p1 p2)[/color]
[color=#444444]    (vla-move obj p2 p1)[/color]
[color=#444444]  )[/color]
[color=#444444]  (setq p1 (vlax-3d-point '(0 0 0)))[/color]
[color=#444444]  (setq p2 (vlax-3d-point '(0 0 1000e99)))[/color]
[color=#444444]  (cond[/color]
[color=#444444]    ((equal (type ss) 'ENAME) (MoveOne ss))[/color]
[color=#444444]    ((equal (type ss) 'PICKSET)[/color]
[color=#444444]     (repeat (setq n (sslength ss))[/color]
[color=#444444]       (MoveOne (ssname ss (setq n (1- n))))[/color]
[color=#444444]     )[/color]
[color=#444444]    )[/color]
[color=#444444]  )[/color]
[color=#444444])[/color]
[/color]

-------------------------------------------

[color=#444444][color=#444444];;DXF[/color][/color]
[color=#444444][color=#444444];;(XX:LeftPick:LineZto0Ent (car(entsel)))[/color]
[color=#444444](defun XX:LeftPick:LineZto0Ent (ss)[/color]
[color=#444444]  (defun MoveOne (e)[/color]
[color=#444444]    (entmod[/color]
[color=#444444]      (mapcar[/color]
[color=#444444]'(lambda (X)[/color]
[color=#444444]    (cond[/color]
[color=#444444]      ((or (equal (car x) 11) (equal (car x) 10)) (list (car x) (cadr x) (caddr x)))[/color]
[color=#444444]      (T x)[/color]
[color=#444444]    )[/color]
[color=#444444]  )[/color]
[color=#444444](entget e)[/color]
[color=#444444]      )[/color]
[color=#444444]    )[/color]
[color=#444444]  )[/color]
[color=#444444]  (cond[/color]
[color=#444444]    ((equal (type ss) 'ENAME) (MoveOne ss))[/color]
[color=#444444]    ((equal (type ss) 'PICKSET)[/color]
[color=#444444]     (repeat (setq n (sslength ss))[/color]
[color=#444444]       (MoveOne (ssname ss (setq n (1- n))))[/color]
[color=#444444]     )     [/color]
[color=#444444]    )[/color]
[color=#444444]  )[/color]
[color=#444444])[/color][/color]

 

DWG file in attachments.

Multi-part archive

 

Need download all and unzip...

help.part1.rar

help.part2.rar

help.part3.rar

Edited by 77077
Link to comment
Share on other sites

Just a comment, I don't have a program that will unrar on my works computer, maybe thats the case with other people, you could maybe try a standard zip file format. :)

Link to comment
Share on other sites

Just a comment, I don't have a program that will unrar on my works computer, maybe thats the case with other people, you could maybe try a standard zip file format. :)

 

sorry ! steven. I use zip, but need Multi-part archive .so the second package suffix is"*.z01" ,can't upload. The file type is not supported.

 

here can download DWG file.

http://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/z-axis-can-t-to-zero/td-p/5270047

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...