Microsoft KB Archive/97851

{| = Excel: PAGE.SETUP? Macro Error Using Fit To Array =
 * width="100%"|

Last reviewed: July 16, 1997

Article ID: Q97851 The information in this article applies to:
 * Microsoft Excel for Windows, versions 4.0 and 4.0a

SUMMARY
In Microsoft Excel, if you use the PAGE.SETUP? function to define the Fit To array as one of the parameters, you will receive the following error message:

Number is not valid If you choose OK, you receive the following error message: Macro Error at Cell: Macro1!A1 However, if you use the same syntax with the PAGE.SETUP function (note that there is no question mark), the function will work as expected (this correct behavior is described in the &quot;Microsoft Excel Function Reference,&quot; version 4.0).

Workarounds
To work around this problem, use either of the following two procedures.

Workaround

  In a new macro sheet, type the following macro: A1: PAGE.SETUP(&quot;&F&quot;,&quot;Page &P&quot;,0.75,0.75,1,1, FALSE,TRUE,FALSE,       FALSE, 1,1,{2,2},1,1,FALSE) A2: PAGE.SETUP? A3: RETURN  Run the macro.

You should not receive a macro error.