Hi,
i just found out about auto lisp a month ago and got interested on it. so i'm really a novice when it comes to making lisp routine. recently, there was this "tip" on making a default value when making a routine and this serves as my pattern. but something is. wrong. it's keeping the string value only once, just to show what is the current value but when you press enter, it's no longer there when you repeat the command unlike in the case of integer, value remains there always.
below is the routine sample.tnx
code:
(defun c:prog1 (/ a b) (if (= gv nil) (setq gv "NAME") );end if (princ "\Member ") (setq a (strcase(getstring))) (if (= gv1 nil) (setq gv1 0) );end if (princ "\Quantity ") (setq b (getint)) (if (= b nil) (setq b gv1) );end if (setq gv a) (princ "\nThe Member is ") (princ a) (setq gv1 b) (princ "\nThe Quantity is ") (princ b) (princ));defun