PDA

View Full Version : Remove Tolerance



robert.1.hall72202
2005-06-08, 01:38 PM
How would I go about making a macro that removes a tolerance from a dimension????
This would be easier than messing around with the properties.

bbapties
2005-06-08, 01:46 PM
which one???..... there is like 15 diferent ones that could be changed..........

i dont think you would be removing them though.....just changing them?

jaberwok
2005-06-08, 01:59 PM
Presumably, it would involve DIMTOL = OFF as an override?

robert.1.hall72202
2005-06-08, 02:06 PM
Im thinking that if I have a tolerance selected (ie. symmetrical, deviation), it would set the tolerance selection to "none" for the chosen dimension.

bbapties
2005-06-08, 02:16 PM
^C^Cdimtol;off;dim;up;\;^C^C

if you normally have your dimtol set to "on" then simply use


^C^Cdimtol;off;dim;up;\;^C^Cdimtol;on;

Will this work?

robert.1.hall72202
2005-06-08, 05:59 PM
That does exactly what I need.........I have a couple routines that add in my most often used tolerances to go with this excellent button to remove them if need be.

This is what I have for adding tolerances in case somebody else wants to use it:



(defun c:T2 (/ Save_DimTol Save_DimTm Save_DimTp DimObject)
(setq Save_DimTol (getvar "DimTol"))
(setq Save_DimTm (getvar "DimTm"))
(setq Save_DimTp (getvar "DimTp"))
(setvar "DimTol" 1)
(setvar "DimTm" 2)
(setvar "DimTp" 2)
(princ "\nSelect Dimension to add Tolerance to: ")
(setq DimObject (ssget '((0 . "DIMENSION"))))
(if DimObject
(command "._-DimStyle" "_A" DimObject "")
)
(setvar "DimTol" Save_DimTol)
(setvar "DimTm" Save_DimTm)
(setvar "DimTp" Save_DimTp)
(princ)
)