; This program selects all dimensions and places them

; on a user-specified layer.

; Modified by Igal Averbuh 2015

(defun C:Dil (/ SETD LAY) ; Begin function

(setvar "CMDECHO" 0) ; Turn off command echo

(setq SETD (ssget "X" '((0 . "DIMENSION")))) ; Selection set of dims

(if (null SETD) ; If there are no dims

(princ "\nThere are no associated dimensions.") ; THEN tell user

(progn ; ELSE begin (progn)

;(setq LAY (getstring "\nTransfer to which layer? ")) ; Get layer name

(command "-layer" "n" "0-DIM" "C" "242" "0-DIM" "")

(command ".CHPROP" SETD "" "LA" "0-DIM" "") ; Change dimensions to layer

) ; End (progn)

) ; End (if)

(setvar "CMDECHO" 1) ; Turn on command echo

(princ) ; Clean exit

) ; End function

; - -( End of Program )- -

(c:dil)

Advertisements