Solved

Too Many Fields defined.  How to load a dbf file with more than 255 fields? Visual Basic 6 pro, vb6

Posted on 2010-11-27
2
809 Views
Last Modified: 2012-05-10
I am using this line to open a dbf file:

Dim db As Database
Dim rs As Recordset
Set db = OpenDatabase("Z:\aloha\vb\dbf\", True, False, "dBASE IV;")
Set rs = db.OpenRecordset("Select * From ITM.DBF Order By ID")

Do While Not rs.EOF
rs.Fields("SHORTNAME")

ETC....ETC....ETC...

The code works great if the database has 255 or less Fields.  How can I load a dbf file that has more than 255 fields.  

I am using VB6pro

Thanks in advanced.
0
Comment
Question by:daneburr
2 Comments
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 500 total points
ID: 34224966
Does it work if you list the only some of fields in the Select?

e.g. "Select Field1, Field2  From ITM.DBF Order By ID"


Have you tried ADO instead of DAO?

0
 

Author Closing Comment

by:daneburr
ID: 34230121
It worked.
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

CCModeler offers a way to enter basic information like entities, attributes and relationships and export them as yEd or erviz diagram. It also can import existing Access or SQL Server tables with relationships.
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question