PRB: Capital "S" Not Displayed When Using the Text ISAM

Last reviewed: May 22, 1996
Article ID: Q145769
The information in this article applies to:
  • Standard, Professional, and Enterprise Editions of Microsoft Visual Basic, 16-bit and 32-bit, for Windows, version 4.0

SYMPTOMS

Text files that contain a capital "S" in a column by themselves display as "0". The rest of the characters for that column are not displayed.

MORE INFORMATION

The text file is not in the format Visual Basic expects it to be in. Visual Basic expects to find "" around each and every entry in the text file.

Steps to Reproduce the Problem

  1. Create a text file with following text. Save it as a text file.

          FirstName, MiddleInitial, LastName, age, address
          Chris ,B ,Barr ,30 , 200 main st
          Charles ,S, Sterling, 27 ,100 1st street
    

  2. Start Visual Basic. Form1 is created by default.

  3. Add a data control to form1.

  4. In the properties for the data1 control, choose Text for the connect property and select the text file for the database name.

  5. Add a DBGrid control to the form and select Data1 as the datasource.

  6. Run the project (press F5).

    Results:

          Chris       Barr      30  200 main st
          Charles  0  Sterling  27  100 1st street
    
       The "B" middle initial (in the first record) is now blank. The "S"
       middle initial (in the second record) is now a "0".
    
    

Resolution

The above file is not in the format Visual Basic expects; comma separated text needs to be in the following format:

   "FirstName", "MiddleInitial", "LastName", "age", "address"
   "Chris","B","Barr",30,"200 main st"
   "Charles","S","Sterling",27,"100 1st street"

STATUS

This behavior is by design.

REFERENCES

For more information on the Text ISAM and Accessing Data in a Text Document, search for the keyword "schema.ini" in the Visual basic online help.


Additional reference words: 4.00 vb4win vb4all
KBCategory: kbprg
KBSubcategory: APrgDataOther APrgDataIISAM


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