FindFile .SearchPath Argument Ignored with File Extension

Last reviewed: July 30, 1997
Article ID: Q106653
The information in this article applies to:
  • Microsoft Word for Windows, versions 6.0, 6.0a, 6.0c
  • Microsoft Windows operating system version 3.1

SYMPTOMS

If a file specification (for example, *.doc) is included in the .SearchPath parameter of the FileFind command, that parameter will be ignored.

CAUSE

Because Word 6.0 can search for multiple file extensions, it does not accept file specifications on the end of the .SearchPath parameter. Below is an example of a FileFind .SearchPath parameter that is valid in Word 2.x but ignored in Word 6.0:

   FileFind .SearchPath = "C:\Winword\*.Doc"

A correct .SearchPath parameter for Word 6.0 is

   FileFind .SearchPath = "C:\Winword"

with the "*.Doc" entered in the .Name parameter if necessary.

When macros are converted from Word 2.x to Word 6.0, file specifications, if any, are not removed from the .SearchPath parameter of the FileFind command. Therefore, these macros--once converted--will not run properly without being edited.

STATUS

Microsoft is researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

Kbcategory: kbusage kbmacro KBSubcategory:


Additional query words: 6.0 File Find Directory winword 6.0a 6.0c
word6 word6
Version : 6.0 6.0a 6.0c
Platform : WINDOWS


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: July 30, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.