asteffy Posted February 29, 2012 Posted February 29, 2012 (edited) I am currenty using a lisp I found and modified that adds +/- the beginning of my dimension text. The current lisp is: Does anyone know how to modify the dimension precision to 1" inside this routine when +/- is added? Thanks Edited February 29, 2012 by asteffy Quote
Lee Mac Posted February 29, 2012 Posted February 29, 2012 The Dimension Precision will be controlled by your Dimension Style. Quote
asteffy Posted February 29, 2012 Author Posted February 29, 2012 Correct, wasn't sure if this could be incorporated into a lisp? Quote
Lee Mac Posted February 29, 2012 Posted February 29, 2012 Correct, wasn't sure if this could be incorporated into a lisp? A program could be used to attach the relevant Dimension Style Override XData to selected Dimensions, but it would be far easier to simply modify your Dimension Style and click on the Dimension Update button on the Dimensions Toolbar. Quote
SLW210 Posted February 29, 2012 Posted February 29, 2012 asteffy, Please read the CODE POSTING GUIDELINES. And edit your post. Quote
alanjt Posted February 29, 2012 Posted February 29, 2012 It can be (see below). However, a separate dimension style might save you some headaches/work... (defun c:test (/ ss i o) (vl-load-com) (if (setq ss (ssget '((0 . "*DIMENSION")))) (repeat (setq i (sslength ss)) (vla-put-PrimaryUnitsPrecision (setq o (vlax-ename->vla-object (ssname ss (setq i (1- i))))) 1 ) (vla-put-TextOverride o "±<>") ) ) (princ) ) Quote
asteffy Posted February 29, 2012 Author Posted February 29, 2012 This is very close, however, how would I modify it to nearest whole inch instad of hlaf inch? Quote
alanjt Posted February 29, 2012 Posted February 29, 2012 This is very close, however, how would I modify it to nearest whole inch instad of hlaf inch? Change the "1" for vla-put-PrimaryUnitsPrecision to "0". Quote
alanjt Posted February 29, 2012 Posted February 29, 2012 Thanks for the help No problem. As I said, a separate style *might* be less legwork. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.