Microsoft KB Archive/135496

= Microsoft Knowledge Base =

TEXTREF Returns #REF! If Filename Has Special Characters
Last reviewed: March 27, 1997

Article ID: Q135496

3.x 4.x 5.x 7.00 | 3.00 4.00 5.00 5.00a

WINDOWS         | MACINTOSH kbusage

The information in this article applies to:


 * Microsoft Excel for Windows, versions 3.0, 4.0, 5.0 and 5.0c
 * Microsoft Excel for the Macintosh, versions 3.0, 4.0, 5.0 and 5.0a
 * Microsoft Excel for Windows NT, version 5.0
 * Microsoft Excel for Windows 95, version 7.0

SYMPTOMS
When you use the following Microsoft Excel 4.0 macro command with a filename that contains a special character, the macro will return a #REF! error:

=TEXTREF(GET.DOCUMENT(1)&"!R1C1")

WORKAROUND
To work around this problem, do not use special characters in filenames.

MORE INFORMATION
The following table lists the special characters that will cause this problem.

Character Name of character --

`           Accent grave &           Ampersand *           Asterisk @           At symbol \           Backslash {}          Braces []          Brackets ^           Caret $           Dollar sign =           Equal sign !           Exclamation point /           Forward slash >           Greater than sign -           Hyphen <           Less than sign Parentheses %           Percent sign |           Pipe symbol +           Plus sign #           Pound sign ~           Tilde