(defun C:get_points_on_line_acad_points (/ DIST FLAG H-CURRENT INSERT-POINT LIST-CONTURS LIST-POINTS P-MAX P-MIN P1 P2 SEKTION)
  (load_global_variable)
  (setq sektion 1.0)
  (if (setq p1(get-point-get_points_on_line_acad_points))
    (progn
      (princ (strcat "\nВыбранна точка с отметкой: "(rtos (nth 2 p1) 2 2)))
      (if (setq p2(get-point-get_points_on_line_acad_points))
	(progn
	  (princ (strcat "\nВыбранна точка с отметкой: "(rtos (nth 2 p2) 2 2)))
	  (if (not (=(nth 2 p1)(nth 2 p2)))
	    (if (<(nth 2 p1)(nth 2 p2))
	      (setq list-points (list p1 p2))
	      (setq list-points (list p2 p1))
	      )
	    (princ "\nМежду выбранными точками нет превышения.")
	    )
	  (princ list-points)
	  (if list-points
	    (progn
	      (setq p-min (nth 0 list-points))
	      (setq p-max (nth 1 list-points))
	      (setq dist (distance p-min p-max))
	      (setq H-current (*(fix(/(nth 2 p-min)sektion))sektion))
	      
	      (while (not flag)
		(setq H-current (+ H-current sektion))
		(if (< H-current (nth 2 p-max))
		  (setq list-conturs (append list-conturs (list H-current)))
		  (setq flag T)
		  )
		)
	      (if list-conturs
		(progn
		  (vla-StartUndoMark active_document)
		  (draw-line-vla-by-list-property
		    (list
		      (cons "spece" (if (eq (getvar "CTAB")"Model")model_spece paper_spece))
		      (cons "StartPoint" p-min)
		      (cons "EndPoint" p-max)
		      ))
		(foreach x list-conturs
		  (setq insert-point (polar p-min (angle p-min p-max) (/(* dist (- x (nth 2 p-min)))(- (nth 2 p-max) (nth 2 p-min)))))
		  (draw-point-vla-by-list-property
		      (list
			(cons "spece" (if (eq (getvar "CTAB")"Model")model_spece paper_spece))
			(cons "Coordinates" insert-point)
			))
		  (draw-text-vla-by-list-property
		    (list
		      (cons "spece" (if (eq (getvar "CTAB")"Model")model_spece paper_spece))
		      (cons "TextString" (strcat" "(rtos x 2 2)))
		      (cons "InsertionPoint" insert-point)
		      (cons "Height" (/ 2.0 (format_scale_kof)))
		      (cons "Rotation" 0.0)
		      
		      (cons "Alignment" 9)
		      ))
		  
		  )
		  (vla-EndUndoMark active_document)
		)
		(princ "\nМежду выбранными точками нет горизонталей.")
		)
	      )
	    )
	  )
	)
      )
    )
  (princ)
  )



(defun get-point-get_points_on_line_acad_points ( / FLAG OBJ RESULT-POINT TEMP)
  (setq flag T)
  (while flag
    (setq temp(entsel "\nВыбери точку: "))
  (if (eq(type temp)'list)
      (setq obj (car temp))
      (setq obj temp))
    (if obj
      (cond
	((eq (cdr(assoc 0 (entget obj))) "TEXT")
	 (setq result-point(get-item-by-name-in-list (entget obj) 11))
	 (setq flag nil)
	 )
	((eq (cdr(assoc 0 (entget obj))) "POINT")
	 (setq result-point(get-item-by-name-in-list (entget obj) 10))
	 (setq flag nil)
	 )
	(T
	 (alert "Ошибка! Выбран не объект не допустимого типа. Допускаются однострочный текст и точки acad. Попробуй снова.")
	 )
	)
      (alert "Ошибка! Ничего не выбрано. Попробуй снова.")
      )
  )
  result-point
  )