Microsoft KB Archive/102982

From BetaArchive Wiki
< Microsoft KB Archive
Revision as of 08:24, 20 July 2020 by X010 (talk | contribs) (Text replacement - """ to """)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Excel: Can't Use Metric Measurements with PAGE.SETUP()

Last reviewed: June 30, 1997
Article ID: Q102982

The information in this article applies to:

  • Microsoft Excel for Windows, versions 3.0, 4.0, and 4.0a

SUMMARY

In Microsoft Excel for Windows, the PAGE.SETUP() macro command will present the margin arguments in English (inch) measurements regardless of the measurement setting selected under the International Settings section in Windows Control Panel. This may cause larger print margins than expected when using metric measurements.

MORE INFORMATION

The PAGE.SETUP() function allows you to control Page Setup options such as orientation and margin settings from a Microsoft Excel macro. However, this command always presents its arguments for margin settings in English measurements regardless of the measurement settings in Windows Control Panel. This may result in larger print margins being set on the document when working with the metric measurement setting.

For example, the following macro

   =PAGE.SETUP(,,2,2,2,2)
   =RETURN()

will correctly set left, right, top, and bottom margins to 2 inches when using English measurements in the Windows Control Panel. However, if the intention was to set the margins at 2 centimeters, the macro will set your margins to 5.1 centimeters (2 inches roughly equals 5.1 centimeters).

WORKAROUND

When you use the PAGE.SETUP() macro command with metric measurements, enter the margins arguments in the inches equivalent for the centimeter settings you require.

For example, the following macro

     =PAGE.SETUP(,,0.787,0.787,0.787,0.787)
     =RETURN()

will set left right top, and bottom margins to 2 centimeters when using metric measurements in Windows Control Panel (0.787 Inches roughly equals 2 Centimeters).

REFERENCES

"User's Guide 1," pages 530-531 "Function Reference," pages 312-314


Additional reference words: 4.00 4.00a localize localized standard

Keywords : kbmacro kbprb kbprg kbprb
Version : 3.00 4.00 4.00a
Platform : WINDOWS


Last reviewed: June 30, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.