(defun c:dxjc()
(setq EnAng 25)
(setq StpAng 30)
(setq StpDis 2.0)
(setq SearchR 5.0)
(setq blc 1)
(setq bz1 0 bz2 0)
(setq mm1 0 mm2 0)
(setq StpDis (* StpDis Blc))
(setq gc (strcat "\n输入高程点所在图层:"))
(setq jqxc (strcat "\n输入计曲线所在图层:"))
(setq sqxc (strcat "\n输入首曲线所在图层:"))
(setq gcd (getstring gc))
(setq jqx (getstring jqxc))
(setq sqx (getstring sqxc))
(setq LaJqx (strcase jqx))
(setq LaSqx (strcase sqx))
(setq ss (ssget "X" (list (cons 0 "INSERT") (cons 8 gcd))))
(setq m 0)
(setq l 0)
(if (/= ss nil)
(progn
(while (setq tname (ssname ss m))
(setq ed (entget tname))
(setq zb (cdr (assoc 10 ed)))
(setq z (last (assoc 10 ed)))
(setq Pnt0 zb)
; (command"zoom" "