The information in this article applies to:
SYMPTOMSIn Microsoft Excel version 5.0, if you use a Visual Basic, Applications Edition, subroutine to define a name on a worksheet and the name of the worksheet contains a space, the name is not defined correctly. CAUSEThis problem may occur if you use the following syntax to define a name:
If you use this syntax to define a name, the name may be incorrectly
defined if the worksheet name contains a space. For example, if the
worksheet name is "Sales Summary" and the range to refer to is $A$1,
the name may be defined as
This defined name refers instead to the intersection of the ranges 'Sales'
and 'SUMMARY!$A$1' instead of cell $A$1 on 'Sales Summary'.
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem was corrected in Microsoft Excel for Windows version 5.0c. WORKAROUNDTo avoid this problem, use the Names.Add syntax to define names in a Visual Basic subroutine, as in the following example:
Note the use of apostrophes (') in the RefersTo argument. These apostrophes
are included to ensure that the worksheet name is treated as a single name,
instead of as two words separated by a space.
Using the above example, the name would be defined as
This is the correct definition of the name.
Additional query words:
Keywords : kbprg |
Last Reviewed: October 25, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |