Jump to content

Change inch to feet in Bearing Lisp


Recommended Posts

pattanasio

Dear Sir/Madam:

 

The attached lisp routine places the bearing and distance of a line in AutoCAD.  However, it places the inches of the line.  I would like it to indicate feet and decimals of a foot.  This is the format for survey work.  I have been trying to divide the inch result by 12 to derive feet instead. For example (/ distn 12).  Need your help.

 

Thanks,

Phil

 

 

 

 

bd.LSP

Link to post
Share on other sites
Berzerker

wouldn't you "times" by 12. It takes 12 in. to make a foot.

 

Edited by Berzerker
Link to post
Share on other sites
tombu

As the attached lisp uses no local variables while modifying so many system variables rather than attempting to fix it why not do a search for a better replacement. Many have been written for this purpose with or without using fields or blocks that wouldn't adversely affect anything else in AutoCAD.

Link to post
Share on other sites
pattanasio

This routine gives the distance in decimal inches. If you divide by 12 you will get feet. ie, 120 inches (10 feet) /12 =10 feet.

I finally figured to change the len variable to (setq len (/ len 12)).  This would divide the length (len) by 12 and the output is in feet and decimal of feet.

I renamed the lisp routine to bearing & distance.lsp.

 

Thanks,

Phil

bearing & distance.LSP

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