Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Is there a combination extension & perdendicular?

4 REPLIES 4
Reply
Message 1 of 5
draftsdi
228 Views, 4 Replies

Is there a combination extension & perdendicular?

I am looking for a lisp that would work similar to the ‘extension’ object snap. Kind of a combination of extension and perpendicular where you could select a point (endpoint, midpoint) on a line/polyline traverse the line a user specified distance (similar to the extension object snap) then specify a perpendicular distance to locate the beginning point of the object to be drawn.

4 REPLIES 4
Message 2 of 5
marko_ribar
in reply to: draftsdi

Hi, draftsdi...

 

Just align UCS, so that X axis is pointing thowards extension and coordinate origin is at the end of aligned entity... Then you can simple use LINE command or similar, and type for first point

 

"_non" @extension in X dir,extension in Y dir... ("_non" @110.0,75.0) or ("_non" @110.0,-75.0)...

 

 

HTH, M.R.

Marko Ribar, d.i.a. (graduated engineer of architecture)
Message 3 of 5
draftsdi
in reply to: draftsdi

Thanks for your response but I don't want to have to constantly change UCS and it's too much typing. I want something that will do the work for me.

Message 4 of 5
marko_ribar
in reply to: draftsdi


@draftsdi wrote:

Thanks for your response but I don't want to have to constantly change UCS and it's too much typing. I want something that will do the work for me.


Do you happen to know that you can make lisp that will follow your inputs, avoiding to type commands that are needed for that specific operation?

Marko Ribar, d.i.a. (graduated engineer of architecture)
Message 5 of 5
marko_ribar
in reply to: marko_ribar

(defun c:pp ( / pt ptw )
  (command "_.ucs" "_ob")
  (while (> (getvar 'cmdactive) 0) (command "\\"))
  (setq pt (getpoint "\nSpecify point in changed UCS : "))
  (setq ptw (trans pt 1 0))
  (command "_.ucs" "_p")
  (setvar 'lastpoint (trans ptw 0 1))
  (princ)
)

 Just load pp.lsp, type pp at command prompt, pick curve entity end point, and specify coordinates... After pp has finished, use command you want - like "LINE" or similar and when asked for first point specify @ symbol and hit ENTER... That's it point was saved into 'lastpoint sysvar...

 

HTH, M.R.

Marko Ribar, d.i.a. (graduated engineer of architecture)

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost