Jump to content

Recommended Posts

Posted

Hi All

 

I'm look for a macro or lips to create Feet-Inch calculator (specially adding feet-inch to feet-inch and other math operations). working in architectural design requires in many occasions adding and subtraction feet-inch calculations

 

Thanks

Posted

Use the distof function to convert everything to decimal, perform the arithmetic, then use the rtos function to convert back to feet/inches.

 

Quick example:

(defun c:add ( / _getnumber tot num )

   (defun _getnumber ( msg / str num )
       (while (not (or (eq "" (setq str (getstring t msg))) (setq num (distof str))))
           (princ "\nPlease enter a number.")
       )
       num
   )

   (if (setq tot (_getnumber "\nSpecify Amount: "))
       (while (setq num (_getnumber "\nSpecify Amount to Add <Exit>: "))
           (princ (strcat "Total: " (rtos (setq tot (+ num tot)))))
       )
   )
   (princ)
)

Posted

Or just buy the right calculator (since you'll be doing this addition quite often).

Posted

Have you decided which log-in you wanted to keep?

Posted

Enter QC in the command line to open the "Quick Calculator"

Make sure that your units are set in your drawing accordingly...

The trick for using fractional inches that I have found is to use the minus sign as a spacer between the whole inch and the fractional inch:

2 1/2" = 2-1/2"

Others have had success using a regular space, but I find using the minus sign works...

QuickCalculator.jpg

Posted

Is it so complicated to be written in Lisp and Dcl files?

Posted

Perhaps you can write a lisp routine and share it with us. That would be very nice of you.

Posted
Perhaps you can write a lisp routine and share it with us. That would be very nice of you.

 

I wish I can, I would not ask for it in the first place,

 

 

Any How thanks for the reply

 

 

Wonder-Man

Posted
As shown in post #7, there is already one inside of AutoCAD

 

I did try it. It is not handy as a real calc.

 

Thank for the answer

Posted
It is not handy as a real calc.

Then why are you asking for a LISP routine?

Posted

oK alanjt, let me explain exactly what I wish to find... you know some time you find a lips routine comes with a dcl file and can be a regular calculator, now instead a regular calc I like to find a calculator that do the addition and the subtraction of the feet and the inches it is similar to what post #2 shown.

 

Thanks for the reply

Posted

Thanks for the link, Wonder-Man, I'll check it out.

I recommend the hand held Jobber 6. I still use a Jobber 5 that I bought many years ago. My first was a Jobber II.

For $70, unless you go together with some co-workers to get the $55 price, gets you an instrument you can use anywhere, anytime.

 

digger

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