ID: Q138274
The information in this article applies to:
When you use any of the following WordBasic commands, the information may be returned in either all uppercase letters or mixed uppercase and lowercase letters.
FileName$()
Files$()
GetAddinName$()
SelectionFileName$()
FileNameInfo$()
Any file or folder (directory) originally created under MS-DOS will be returned in all uppercase letters.
Files and folders created under Windows 95 are returned with the same capitalization as they were created.
For example, if you create a file in MS-DOS named OLDDOS.TXT and run the following macro on it:
Sub MAIN
MsgBox FileName$()
End Sub
Word will show its name as
C:\My documents\DOSDIR\OLDDOS.TXT
Give the file or folder a new name in Windows 95:
1. Using Windows Explorer, click the file or folder.
2. Press F2 and type a different temporary name.
3. Press ENTER.
4. Press F2 and retype the original name with the desired capitalization.
5. Press ENTER.
The WordBasic commands will now return the expected results.
Renaming the file or folder with the same name isn't sufficient; you must give the file a new name first and then give it the original name.
KBCategory: kbusage KBSubcategory: kbmacro Additional reference words: 7.0 word95 word7 file macro capital winword upper case lower case
Keywords : kbmacro
Version : 7.0
Platform : WINDOWS
Last Reviewed: February 5, 1998