View Full Version : Dimscale now in feet?
chuck_cantieny
2010-05-11, 12:00 AM
I am updating a menu that has been used in 2004 up till now. The menu calls the DIMSCALE system variable to scale a block when inserted. With 2010 and 2011 it would appear that Autocad returns the value in feet if drawing units are set to architecural or engineering. It returns the value in inches if units are decimal. This is causing my blocks to be scaled by 8 (as in 8 feet) not 96. Using dimscale as auxilary scale in a tool palette works correctly reguardless of drawing units. The help shows DIMSCALE as a real number not a linear measurment. Any ideas how to work around this so the insert scale is not dependent on drawing units?
Thanks Chuck
RobertB
2010-05-11, 01:14 AM
What are you using in the CUI command macro?
(getvar "DimScale") returns the correct value even when units are arch/eng.
chuck_cantieny
2010-05-11, 01:37 AM
^C^C-insert ELTAG \(GETVAR "DIMSCALE");;;
If I list the block after the insert it lists the scale as 8 not 96. But as you say if I type the (GETVAR "DIMSCALE") at the command line it returns 96.0. I don't get it.
Chuck
^C^C-insert ELTAG \(GETVAR "DIMSCALE");;;
If I list the block after the insert it lists the scale as 8 not 96. But as you say if I type the (GETVAR "DIMSCALE") at the command line it returns 96.0. I don't get it.
Chuck
Are any of the system variables discussed in this thread, "Blocks, Images or Xrefs not inserting correctly?," set to the wrong value?
irneb
2010-05-11, 05:55 AM
Yep, it sounds as if your INSUNITS is set to 2 (feet) instead of 1 (inches). You'll need to check this variable in both the current drawing as well as change the units property (Property palette) inside the BEdit command. Or you could first WBlock the block out, open that DWG file, change its INSUNITS, save & close, and then insert & redefine from file.
Unfortunately existing insertions of this block won't automatically rescale themselves if you simply change its units property. You'll have to modify the scale property of all the block references to achieve that.
chuck_cantieny
2010-05-12, 11:34 AM
My unsuinits was set to 0 in both drawings. If I started a new drawing with the 2011 standard acad.dwt the block would insert OK. I just copied everything from the old template into the a new drawing and created a new template.
Chuck
scott.wilcox
2010-05-12, 01:22 PM
Type -DWGUNITS ad see if your units are assigned there.
There are actually three variables (at least) that could cause this behavior.
INSUNITS - Specifies a drawing-units value for automatic scaling of blocks, images, or xrefs inserted or attached to a drawing.
INSUNITSDEFSOURCE - Sets source content units value when INSUNITS is set to 0. Valid range is 0 to 20.
INSUNITSDEFTARGET - Sets target drawing units value when INSUNITS is set to 0. Valid range is 0 to 20.
chuck_cantieny
2010-05-13, 11:59 PM
I tried -DWGUNITS and got this:
Command: -DWGUNITS
c:\program files\autodesk\autocad lt 2011\aecuibase.arx cannot find a procedure
that it needs.
Unknown command "-DWGUNITS". Press F1 for help.
INSUNITS, INSUNITSDEFSOURCE and INSUNITSDEFTARGET all set to 1
It still is setting the scale to 8 not 96.
What I really don't understand is if I type dimscale at the command line it shows the current value of 8'-0" (if units are set to architectural or engineering). Dimscale is a multiplyer not a length! You can't scale somthing 8'-0"!!! If you look at the dimscale in the dimension style manager it shows 96 as it should. And it works with tool palettes.
Chuck
cadtag
2010-05-14, 03:12 PM
...
What I really don't understand is if I type dimscale at the command line it shows the current value of 8'-0" (if units are set to architectural or engineering). Dimscale is a multiplyer not a length! You can't scale somthing 8'-0"!!! ...
Chuck
8'-0" IS a number -- it's just formatted according to your units settings. to CAD, all a distance is is a number, and you can use (getdist) anytime a real number is requested by the software.
What CAD doesn't know, is what a distance is.... whether feet, furlongs, or parsecs. it's all numbers to CAD
chuck_cantieny
2010-05-14, 09:35 PM
8'-0" IS NOT a number. It is a linear distance.
Distance is not just a "number" of "units" it is a "number" of "linear units"
Clearly 8 FEET - 0 INCHES is a number of linear units.
AutoCAD tries to pretend it is "unitless" because that's cool now. But back in the day it didn't even try to pretend. It was inches baby and architectural and engineering units tell the tale. I think they even used to say it in some of their documentation. There is only one unit you can divide by 12 and get feet. OK so maybe they never figured they would be selling outside the US of A. I don't know. But I digress....
Back to the matter at hand - Set your linear units to architectural. Open the dimension style manager and look at all the sizes. All of them in feet, inches and fractions, right? Numbers and linear units, each end every one. Now look at DIMSCALE. Dimscale is a number, a unitless multiplier, as it should be, as it must be. But somehow AutoCAD has slipped up and let units get to DIMSCALE. Somewhere in the effort to be "unitless" and be able to share with other "units" something went terribly wrong! Now if you type DIMSCALE at the command line instead of the sweet joy of a unitless multiplier you get the bitter disappointment of a distance. Now insertion macros that have worked for years suddenly don't. Your heart is breaking….your….Oh……Sorry…..
Plus this is an upgrade from 2002 so I don’t know when this started. Anyway the DIMSCALE adjustment still works if you use it in a tool palette insert so I guess AutoCAD figures everyone must be inserting scaled blocks that way. This may be the way I have to insert scaled blocks in the future.
Don't even get me started on decimal feet! (Like why you can input them but not list them.)
Resistance is futile……..
Thanks. I feel better now.
Chuck
jaberwok
2010-05-14, 11:00 PM
AutoCAD tries to pretend it is "unitless" because that's cool now. But back in the day it didn't even try to pretend. It was inches baby and architectural and engineering units tell the tale.
Autocad works in "drawing units" and one drawing unit equals whatever the draughtsman thinks it is in the real world. That's how it has always been.
Thanks. I feel better now.
Good. 8) Now, back to the problem ...
RobertB
2010-05-15, 01:39 AM
What I really don't understand is if I type dimscale at the command line it shows the current value of 8'-0" (if units are set to architectural or engineering). Dimscale is a [multiplier] not a length! That isn't really a valid test. Looking directly at DimScale is going to report the value in the current units. Looking at DimScale via Visual LISP is going to report the value in decimal units.
Command: LUnits
Enter new value for LUNITS <4>:
Command: DimScale
Enter new value for DIMSCALE <0'-1">:
Command: DimScale
Enter new value for DIMSCALE <0'-1">: 96
Command: DimScale
Enter new value for DIMSCALE <8'-0">:
Command: (getvar "DimScale")
96.0
FWIW, even AutoCAD 2002 acts this way. See the attached image.
So what we really need is for you to upload a sample drawing with one of your blocks incorrectly inserted.
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.