Read DBase IV files with VB 3.0 Prof. 
Author Message
 Read DBase IV files with VB 3.0 Prof.

I have a problem when I am trying to read a DBF IV database who I made from
Excel ( save as).
Here, the second instruction is not good:
        Set db = OpenDatabase(NameFile$, 0, 0, "DBASE IV;")
        Set nametable = db.OpenTable("name"), because VB don't find the name in question.

And if I try these instructions:
        On error resume next
        Set db = OpenDatabase(Fichier$, 0, 0, "DBASE IV;")
         MsgBox "nb tables=" & db.TableDefs.Count
Vb inform me that there is no table.

But when I open the same file  with Data Manager or VisData, no problem, I get all the data because these programs give the same name to the first table then the name of the file.

How can we open and work with tables from a DBASE file created from Works or Excel with VB 3.0 ?

Thank you
Francois Charbonneau
Montreal



Thu, 26 Jun 1997 23:55:11 GMT  
 Read DBase IV files with VB 3.0 Prof.
: I have a problem when I am trying to read a DBF IV database who I made from
: Excel ( save as).
: Here, the second instruction is not good:
:       Set db = OpenDatabase(NameFile$, 0, 0, "DBASE IV;")
:       Set nametable = db.OpenTable("name"), because VB don't find the name in question.

Your [NameFile$] should be the directory path to your .DBF files

: And if I try these instructions:
:       On error resume next
:       Set db = OpenDatabase(Fichier$, 0, 0, "DBASE IV;")
:        MsgBox "nb tables=" & db.TableDefs.Count
: Vb inform me that there is no table.

Your table name should be the .DBF file

--
/~ ~__~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ \
/  |__ ilent Dreamer  ~{CN!!VP!!HK~}  Denny Quek C.H.   .;;;.         \  

/       Html:   http://www.iscs.nus.sg/~quekchue    \=/   <snore>\
/                                                                     \
/~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~  ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ \



Tue, 01 Jul 1997 13:43:14 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Read DBase IV with VB 3.0 Professionnal

2. Read a DBase IV file in a VB 3.0 Prof. program

3. VB 3.0 + dBase IV+Acess 2.0

4. VB 3.0 Pro, CodeBasic 5.1 and DBase IV Question

5. VB 3.0 and dBASE IV

6. VB 3.0 Pro, CodeBasic 5.1 and DBase IV question

7. Reading fields from a dbase IV file

8. How can I read record from dBase IV (.DBF) with VB 6

9. VB/Access and dBASE IV mdx files?

10. VB and dBASE IV files

11. DBASE III- having problems reading dBASE files to VB

12. How to read dBASE IV with ODBC 32?

 

 
Powered by phpBB® Forum Software