Search the Community
Showing results for tags 'ordi'.
-
change ordi.lsp to feet and inches from decimal inches?
losquest posted a topic in AutoLISP, Visual LISP & DCL
I found the lsp routine from ASMI titled ORDI.lsp and it works great but I can not get it to output the coordinates in feet and inches. I'm a lowly architect who has no clue how to create/edit lisp files but am willing to try with some help. Below is the lisp routine for reference. thanks all who reply!!! ;; ==================================================================== ;; ;; ;; ;; ORDI.LSP - This lisp for labeling X,Y coordinates with ;; ;; standard _DIMORDINATE dimension. The dimension ;; ;; properties is defined by current dimension ;; ;; style and variables DIMSCALE, DIMLFAC ;; ;; and DIMDEC. ;; ;; ;; ;; ==================================================================== ;; ;; ;; ;; Command(s) to call: ORDI ;; ;; ;; ;; ... and pick, pick, pick... till Esc is pressed. ;; ;; ;; ;; ==================================================================== ;; ;; ;; ;; THIS PROGRAM AND PARTS OF IT MAY REPRODUCED BY ANY METHOD ON ANY ;; ;; MEDIUM FOR ANY REASON. YOU CAN USE OR MODIFY THIS PROGRAM OR ;; ;; PARTS OF IT ABSOLUTELY FREE. ;; ;; ;; ;; THIS PROGRAM PROVIDES 'AS IS' WITH ALL FAULTS AND SPECIFICALLY ;; ;; DISCLAIMS ANY IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS ;; ;; FOR A PARTICULAR USE. ;; ;; ;; ;; ==================================================================== ;; ;; ;; ;; V1.3, 12 May, 2005, Riga, Latvia ;; ;; © Aleksandr Smirnov (ASMI) ;; ;; For AutoCAD 2000 - 2008 (isn't tested in a next versions) ;; ;; ;; ;; http://www.asmitools.com ;; ;; ;; ;; ==================================================================== ;; (defun c:ordi(/ fPt oldEcho dFlc dDec *error*) (defun *error*(msg) (setvar "CMDECHO" oldEcho) (princ) ); end of *error* (princ(strcat "DIMSCALE="(rtos (getvar "DIMSCALE"))" " "DIMLFAC="(rtos (setq dFlc (getvar "DIMLFAC")))" " "DIMDEC="(rtos (setq dDec (getvar "DIMDEC")))" " ); end strcat ); end princ (setq oldEcho(getvar "CMDECHO")) (setvar "CMDECHO" 0) (princ "\n>> ") (while T (if (setq fPt(getpoint)) (progn (command "_.dimordinate" fPt "_t" (strcat "X=" (rtos(* dFlc(car fPt))2 dDec) "\\X" "Y=" (rtos(* dFlc(cadr fPt))2 dDec) ); end strcat pause ); end command ); end progn ); end if ); end while (setvar "CMDECHO" oldEcho) (princ) ); end of c:ordi (princ "\n[info] http:\\\\http://www.AsmiTools.com [info]") (princ "\n[info] X,Y coordinates labeling. Type ORDI to run. [info]")