I've create a program to measuring length of a line,after load in cad it program can't run,but if I load as step by step (line by line) it can run (not yet perfect),can anybody help to me to correct it,thanks a lot for your kind Best regards Ade Suharna ; ll is stand for measuring length of a line ; Design by Ade Suharna ; 6 June 2004 (defun c:ll () (setq alin (entget (entsel "Please choose start line: "))) (setq adot (entget (entlast))) (setq adot-1 (assoc 10 adot)) (setq adot-2 (cdr adot-1)) (setq blin (entget (entsel "Please choose end line: "))) (setq bdot (entget (entlast))) (setq bdot-1 (assoc 11 bdot)) (setq bdot-2 (cdr bdot-1)) (setq dist_ab (distance adot-2 bdot-2)) (prompt " LENGTH OF LINE: ") (princ dist_ab) (princ) )