Microsoft KB Archive/79587

{| = XL2/XL3: Function Macros Don't Update When Macro Code Is Changed =
 * width="100%"|

Last reviewed: February 2, 1998

Article ID: Q79587

The information in this article applies to:
 * Microsoft Excel for Windows, versions 2.1 and 3.0
 * Microsoft Excel for the Macintosh, versions 2.2 and 3.0
 * Microsoft Excel for OS/2, versions 2.2 and 3.0

SUMMARY
Worksheet values returned by custom function macros in the versions of Microsoft Excel listed above are not automatically updated when you make changes to the function macro code.

MORE INFORMATION
Function macros are read into memory as each equation calling the macro is entered into a spreadsheet cell. To update cells that call a function macro that has been edited, you must reenter the equations in those cells.

To update a function macro in a single cell, follow these steps:


 * 1) Select the cell you want to update.
 * 2) In Microsoft Excel for the Macintosh, press COMMAND+U. In Microsoft Excel for Windows or OS/2, press F2.
 * 3) Press RETURN or ENTER.

The formula will be entered on the spreadsheet and the function macro will be recalculated. To recalculate all cells that refer to a function macro, follow these steps:


 * 1) Select the range of cells containing references to the function macro.
 * 2) On the Formula menu, click Replace.
 * 3) Enter the name of the function macro in the &quot;Find What:&quot; field.
 * 4) Enter the name of the function macro in the &quot;Replace With:&quot; field.
 * 5) Click Replace All.

This will reenter all formulas that contain a reference to the edited function macro and update spreadsheet values accordingly.