Jump to content
rog1n

How control aligment of dynamic block with lisp

Recommended Posts

rog1n

Hello,  I need to select many dynamic blocks then select one polyline and all blocks aligment with this polyline using the tool "aligment of dynamic block". I found this lisp from lee-mac (http://lee-mac.com/objectalign.html) this do almost I need instead of specify the base I need the lisp use aligment. Can anyone help me or give me at least one direction how to do this.

 

 

Example.dwg

Edited by rog1n

Share this post


Link to post
Share on other sites
BIGAL

Have a look at chainage.lsp it uses the 1st derivate of the pline to work out the angle of points along a pline.

 

; obj is vl pline pnt is point on pline

(defun alg-ang (obj pnt)
  (angle '(0. 0. 0.)
     (vlax-curve-getfirstderiv
       obj
       (vlax-curve-getparamatpoint
         obj
         pnt
       )
     )
  )
)

Share this post


Link to post
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
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...