VBE: Cannot Insert File into Module from Disk

Last reviewed: February 3, 1998
Article ID: Q175857
*************************************************************************
   CONFIDENTIAL BETA CONFIDENTIAL BETA CONFIDENTIAL BETA CONFIDENTIAL

   This article discusses a beta test product not yet announced by
   Microsoft. Please feel free to familiarize yourself with this
   product, test it, and report problems to Microsoft.

   CONFIDENTIAL BETA CONFIDENTIAL BETA CONFIDENTIAL BETA CONFIDENTIAL
*************************************************************************

The information in this article applies to:

  • Microsoft Visual Basic for Applications version 5.0
  • Microsoft Excel 98 Macintosh Edition
  • Microsoft Word 98 Macintosh Edition
  • Microsoft PowerPoint 98 Macintosh Edition

SYMPTOMS

When you try to insert the contents of a text file into a Microsoft Visual Basic for Applications module, the file is not inserted.

CAUSE

This problem may occur if the following conditions are true:

  • The text file that you are attempting to insert into the module is stored on a disk.

    -and-

  • The disk containing the file is in MS-DOS format.

    -and-

  • The disk does not have a volume name.

WORKAROUND

To work around the problem, rename the disk. To rename the disk, follow these steps:

  1. On the Application menu, click Finder.

  2. If the desktop is not completely visible, click Hide Others on the Application menu.

  3. On the desktop, click the icon for the disk. Click a second time, and the name of the disk is selected.

  4. Type the new name for the disk, and then press RETURN.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

REFERENCES

For more information about inserting files into a module, click the Office Assistant in the Visual Basic Editor, type "insert file," click Search, and then click to view "Import a Text File into Code."

NOTE: If the Assistant is hidden, click the Office Assistant button on the Standard toolbar. If Microsoft Help is not installed on your computer, please see the following article in the Microsoft Knowledge Base:

   ARTICLE-ID: Q120802
   TITLE     : Office: How to Add/Remove a Single Office
               Program or Component


Additional query words: XL98 kbmacro vba vbe
Keywords : kbprg kbui OffVBA
Version : MACINTOSH:98
Platform : MACINTOSH
Hardware : MAC
Issue type : kbprb
Solution Type : kbworkaround


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: February 3, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.