About units of measure

Microsoft Office ShapeSheet

About units of measure

When you insert fields into text or build formulas, you often specify units of measure for the values you type.

Microsoft Visio evaluates the result of a formula differently depending on the cell in which you enter the formula. In general, cells that represent shape position, a dimension, or an angle require a number-unit pair that consists of a number and the qualifying units needed to interpret the number. Many other cells don't require units and evaluate to a string, to TRUE or FALSE, or to an index. For example, the same formula that in the FillForegnd cell means color 5 from the drawing's color palette means TRUE (and locks the shape's width) in the LockWidth cell.

Always specify a unit of measure when you enter a formula in a cell that expects a dimensional value. If you don't specify a unit of measure, Visio uses the default unit for that cell, which can be page units, drawing units, type units, duration units, or angular units.

Click to show or hide information.Units of measure

You can type units of measure in full or use the alternatives listed in this table.

To specify these units of measure

Use

Automation constant

Centimeters

centimeters, cm., or cm

visCentimeters (69)

Ciceros

ciceros, cicero, ci., ci, or c

visCiceros (54)

Dates

date/time, date, time

visDate (40)

Degrees

degrees, degree, deg., or deg

visDegrees (81)

Didots

didots, didot, di., di, or d

visDidots (53)

Elapsed Weeks

eweek, ew., ew

visElapsedWeek (43)

Elapsed Days

eday, ed., ed

visElapsedDay (44)

Elapsed Hours

ehour, eh., eh

visElapsedHour (45)

Elapsed Minutes

eminute, em., em

visElapsedMin (46)

Elapsed Seconds

esecond, es., es

visElapsedSec (47)

Feet

feet, foot, ft., ft, f, or '

visFeet (66)

Inches

inches, inch, in., in, i or "

visInches (65)

Kilometers

kilometers, km., or km

visKilometers (72)

Meters

meters, meter, metres, metre, m., or m

visMeters (71)

Miles

miles, mile, mi., or mi

visMiles (68)

Millimeters

millimeters, mm., or mm

visMillimeters (70)

Minutes

minutes, minute, min., or min

visMin (84)

Nautical miles

nm.,n.m., or nm

visNautMiles (76)

Percent

%

visPercent (33)

Picas

picas, pica, or p

visPicas (51)

Points

points, point, pt., or pt

visPoints (50)

Radians

radians, radian, rad., or rad

visRadians (83)

Seconds

seconds, second, sec., or sec

visSec (85)

Yards

yards, yard, yds., yds, yd., or yd

visYards (75)

Click to show or hide information.Compound units of measure

In formulas, you can express units of measure for compound numbers using the abbreviations in the following table. The Visio application simplifies the results and displays them in the compound units.

For example, if you enter 45.635 dms, Visio displays the equivalent value as 45° 38' 6".

To specify units

Use this abbreviation

Automation constant

Ciceros and didots

CICERO/DIDOT

visCicerosAndDidots (52)

Degrees, minutes, and seconds

DMS, DEGREES, DEG, °

visDegreeMinSec (82)

Feet and inches

FEET/INCH

visFeetAndInches (67)

Picas and points

PICAPOINTS

visPicasAndPoints (49)

Click to show or hide information.Fractional units of measure

You can specify fractional units of measure in the DrawingScale cell to affect the number of ruler subdivisions that Visio displays in the drawing window. By default, Visio divides distances into tenths when drawing its rulers. If you use fractional units of measure in the DrawingScale cell, Visio divides distance into the following:

  • Eighths for visInchFrac and visMileFrac
  • Twelfths for visFeetAndInches

Fractional units of measure have no effect in cells other than the DrawingScale cell.

To specify fractional units

Use this abbreviation

Automation constant

Inches in fractions

INCHES, IN., IN, ", FRAC_INCHES

visInchFrac (73)

Miles in fractions

MILES, MI., MI, FRAC_MILES

visMileFrac (74)

Feet and inches

FEET/INCH

visFeetAndInches (67)

Click to show or hide information.Multidimensional units of measure

In formulas, you can express units of measure for multidimensional numbers using the abbreviations in the following table. The Visio application simplifies the results and displays them in the multidimensional units.

To specify multidimensional units

Use this abbreviation

Automation constant

Acre

ACRES

visAcre (36)

Centimeters

SQ. CM., SQ CM, CM.^2, CM^2

visCentimeters (69)

Feet

SQ. FT., SQ FT, FT.^2, FT^2

visFeet (66)

Hectare

HECTARES, HECTARE, HA., HA

visHectare (37)

Inches

SQ. IN., SQ IN, IN.^2, IN^2

visInches (65)

Kilometers

SQ. KM., SQ KM, KM.^2, KM ^2

visKilometers (72)

Meters

SQ. M., SQ M, M.^2, M ^2

visMeters (71)

Miles

SQ. MI., SQ MI, MI.^2, MI ^2

visMiles (68)

Millimeters

SQ. MM., SQ MM, MM.^2, MM ^2

visMillimeters (70)

Yards

SQ. YD., SQ YD, YD.^2, YD^2

visYards (75)

Click to show or hide information.Universal strings

In localized versions of Visio applications, the set of recognized strings changes with the language. If you want your program to work with multiple languages, use the universal strings for units of measure.

For

Use

Centimeters

CM

Ciceros

C

Ciceros and didots

CICERO/DIDOT

Date or time

DATE

Degrees

DEG

Degrees, minutes, seconds

°

Didots

D

Elapsed week

EW

Elapsed day

ED

Elapsed hour

EH

Elapsed minute

EM

Elapsed second

ES

Feet

FT

Feet and inches

FEET/INCHES

Inches

IN

Inches in fractions

IN_F

Kilometers

KM

Meters

M

Miles

MI

Miles in fractions

MI_F

Millimeters

MM

Minutes

'

Nautical miles

NM

Percent

%

Picas

P

Picas and points

PICAPOINTS

Points

PT

Radians

RAD

Seconds

"

Yards

YD

Click to show or hide information.Implicit units of measure

When the Visio application parses and stores a number-unit pair, it can use explicit units or implicit units. A number expressed in explicit units always is displayed in the units of measure that were originally entered. A number expressed in implicit units always converts to the equivalent value in the drawing, page, or angular units appropriate for the cell.

For example, suppose you enter the equivalent of 1 inch in cell A using explicit units and in cell B using implicit units, and that both cell A and cell B use drawing units. Next, you change the default units for the page to centimeters. Cell A still displays 1 in., because it uses explicit units that don't change with the defaults. Cell B now displays 2.54 cm, the equivalent value in the default units.

To enter units implicitly, use the following syntax.

number [unit, flag]

number

The original value, such as 3.7, 1.7E-4, or 5 1/2.

unit

The units in which number originally is expressed.

flag

The measurement system to use when the implicit-value unit is displayed. See below for values.

The element flag is one of the following letters (either uppercase or lowercase) indicating the measurement system that should be used when the implicit-value unit is displayed.

flag

Measurement system

Example

a, A

Angular

=5[deg,A]

d, D

Drawing

=5[in,D]

e, E

Duration

=5[eh,E]

p, P

Page

=5[in,P]

t, T

Type

=5[pt,T]

Additionally, you can use the implicit units DL, DP, DT, DA, DE for implicit drawing-, page-, text-, angular-, and time-units, respectively. These units assume the associated value is internal units. For example, if the current measurement system is centimeters, =2 DL would be interpreted as 2 internal units (inches) and displayed as 5.08 cm.

Using the implicit syntax described above, this expression (=2 DL) is equivalent to 2[in,d]. The implicit syntax gives you the choice of how to interpret the value, so you could also specify 2[ft,d], which would be interpreted as 2 feet, and displayed as 60.96 cm. The implicit units DL, DP, DT, DA, and DE are universal, and do not have localized counterparts.

Click to show or hide information.Default units of measure

Following are the default units of measure along with their equivalent settings in the user interface.

Default unit of measure

User interface equivalent

visDrawingUnits

The units in the DrawingScale cell of the page or master containing the cell.

visPageUnits

The units selected in the Page box on the Regional Settings tab in the Options dialog box (on the Tools menu, click Options).

visTypeUnits

The units selected in the Text box on the Regional Settings tab in the Options dialog box.

visAngleUnits

The units selected in the Angle box on the Regional Settings tab in the Options dialog box.

visDurationUnits

The units selected in the Duration box on the Regional Settings tab in the Options dialog box.