Jump to content

Autolisping Visuality commands...


samifox

Recommended Posts

Hi

So far, using Autolisp functions to interact with thec ommand line in Autocad made a perfect scene. What didn’t made scene is how to code "click" on the vector in order fot the function to work.

For example the trim/extends command will trim or extend the line in the direction of the clicked point, how can I tell Autolisp to click in a specific location?

 

Thanks

Shay

Link to comment
Share on other sites

You can provide the points to be picked, similar with what you will do on screen:

(if (and (setq point1st (cadr (entsel)))
        (setq point2nd (cadr (entsel))))
(command "_EXTEND" point1st "" point2nd "")
)

But, please, pay attention that the result may be influenced by the current zoom level and also by pickbox size.

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