【已解决】只需要用命令默认让属性文字反转180,该怎么改一下呀
本帖最后由 yangchao2005090 于 2019-6-14 22:07 编辑(defun c:BAChg (/ key an hi cset)
(initget 128 "R A")
(setq key (getdist "\n字高: "))
(cond
((= (type key) 'STR)
(if (= (strcase key) "R")
(setq key "Recover")
(setq an (getangle "\n旋转角: "))
) ;_ 结束if
)
((= (type key) 'REAL)
(setq hi key)
)
(t)
)
(if (not (vl-catch-all-error-p
(setq cset
(vl-catch-all-apply
'vla-item
(list
(vlax-get-property
(vlax-get-property
(vlax-get-acad-object)
'activedocument
)
'selectionsets
)
"CURRENT"
)
)
)
)
)
(vla-delete cset)
)
(if (or an hi key)
(if (ssget '((0 . "insert")))
(vlax-map-collection
(vlax-get-property
(vlax-get-property (vlax-get-acad-object) 'activedocument)
'activeselectionset
)
'(lambda (x / attlst)
(if (= (vla-get-hasattributes x) :vlax-true)
(progn
(setq
attlst (safearray-value
(vlax-variant-value (vla-getattributes x))
)
)
(mapcar '(lambda (a)
(if hi
(vla-put-height a hi)
)
(if an
(vla-put-rotation a an)
)
(if (= key "Recover")
(vla-put-Backward a :vlax-false)
)
)
attlst
)
)
)
)
)
)
)
(princ)
)
torient 这个命令可以帮到你,需安装cad工具
页:
[1]