If using Vanilla, Text Override is DXF Code 1, else in VL it's the TextOverride Property.
Tolerances are another issue, which you'll have to look up in the VLIDE Help Docs - there are many properties/dxf codes.
Registered forum members do not see this ad.
I'm writing a LISP that uses DIMSCALE. My dimensions have tolerances, and info in Text Override, and none are alike. As soon as DIMSCALE is set, I lose all that info... How would I be able to recall this information from the selection set?? I cant seem to figure it out
If using Vanilla, Text Override is DXF Code 1, else in VL it's the TextOverride Property.
Tolerances are another issue, which you'll have to look up in the VLIDE Help Docs - there are many properties/dxf codes.
Lee Mac Programming
With Mathematics there is the possibility of perfect rigour, so why settle for less?
Just another Swamper
Thanks JPlanera
Here's a small example to retrieve the Text Override for a dimension entity:
Vanilla:
Visual:Code:(defun c:test1 ( / ent ) (if (and (setq ent (car (entsel "\nSelect Dimension: "))) (wcmatch (cdr (assoc 0 (entget ent))) "*DIMENSION") ) (alert (strcat "Text Override:\n" (cdr (assoc 1 (entget ent))))) ) (princ) )
Code:(defun c:test2 ( / ent ) (if (and (setq ent (car (entsel "\nSelect Dimension: "))) (wcmatch (cdr (assoc 0 (entget ent))) "*DIMENSION") ) (alert (strcat "Text Override:\n" (vla-get-TextOverride (vlax-ename->vla-object ent)))) ) (princ) )
Lee Mac Programming
With Mathematics there is the possibility of perfect rigour, so why settle for less?
Just another Swamper
No, thank you!
Vanilla code works fine.
I assume this would be different for multiple dimensions?
Can I use the same format then, to recall tolerances?
For multiple dims you might consider stepping through a SelectionSet:
Tolerances are another issue, I would think it is easier to deal with them using VL, but to be honest, I've not dealt with Tolerances before so I'd have to dig around with the DXF info first.Code:(defun c:test3 ( / i ss ent lst ) (if (setq i -1 ss (ssget '((0 . "*DIMENSION")))) (progn (while (setq ent (ssname ss (setq i (1+ i)))) (setq lst (cons (cdr (assoc 1 (entget ent))) lst)) ) (print (reverse lst)) ) ) (princ) )
Have a look at this reference here, and also the VLIDE Help Docs on the properties of a VLA Dimension Object.
Lee
Lee Mac Programming
With Mathematics there is the possibility of perfect rigour, so why settle for less?
Just another Swamper
Registered forum members do not see this ad.
I will look over this info. Thank you very much for the assistance!
Bookmarks