Request: Routint to turn off C
I'm sure I will be embarrassed at how simple this is but I do not know how to write a simple routine to pick a single dimension and have the center mark setting changed to None.I have to do this often enough that I'd like to have a C:MO (Mark Off) command for this situation. 99% of the time I need the Center Mark on.
I know I can pick it from the Properties Dialog.
I just would like a routine for these instances.
TIA!! Create a second dimstyle with no centre mark and use this when you need it? I was hoping for a quicky two letter command if at all possible... Would this work? Untested...
(defun c:TEst (/ #SS) (cond ((setq #SS (ssget "_:L" '((0 . "DIMENSION")))) (or *AcadDoc* (setq *AcadDoc* (vla-get-activedocument (vlax-get-acad-object)))) (vlax-for x (setq #SS (vla-get-activeselectionset *AcadDoc*)) (vl-catch-all-apply 'vla-put-centertype (list x acCenterNone)) ) ;_ vlax-for (vl-catch-all-apply 'vla-delete (list #SS)) ) ) ;_ cond (princ)) ;_ defun Works like a charm!
Exactly what I was hoping for!!
Thank you SO much!!! I know a tiny bit about lisp but nothing about VLA.
Is is hard to code this in autolisp?
(I was just wondering how hard it would have been to code it in simple lisp)
(ie: How stupid am I really??!!)
If it's too much of a hassle, don't bother (it's works fine)
I'm just wondering from a "I'm trying to learn" standpoint..
thanks again either way! Could you use the properties pallette? ^C^C_DIMCEN;0;^C^C_-dimstyle _apply \\^C^C_DIMCEN;0.09
Put this code into button, replace last #( in red) with your variable.
I know I am late but it is simple to understand.
页:
[1]