Message 1 of 5
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi guys
I'm trying to change the format of the number.
e.g 1478,497m to 1.478,497m
or 1478497,585m to 1.478.497,585m
I've already put the comma. (thanks to ymg sub rotine).
I'd like to put the period.
This is a very old lisp.
(defun C:LP(/ PNT1 P1X P1Y STDY DY COORDN COORDE PTXT) (vl-load-com) ;;; Settings Section Adjust These Values ; (setq decsymb "," ; Decimal Symbol "," or "." ; ) (setq PNT1 (getpoint "\nPick coordinate point: ")) (setq P1X (car pnt1)) ;x coord (setq P1Y (cadr pnt1)) ;y coord (setq STDX (rd (rtos P1X 2 3))) (setq STDY (rd (rtos P1Y 2 3))) (setq COORDN (strcat "N " STDY "m")) (setq COORDE (strcat "E " STDX "m")) (setq PTXT (getpoint "\nPick text location: ")) (command "LEADER" PNT1 PTXT "" COORDN COORDE "") (princ) ) ;; rd function to replace decimal separator in string ; ;; Variable decsymb is defined outside the routine ; ;by ymg (defun rd (str) (vl-string-subst decsymb "." str))
Thanks in advance
Fabrício
Solved! Go to Solution.