Is there a way to read a simple dBase file using vb.net (2008)?
dBase file in VB.Net ?
Collapse
X
-
I'm not sure what a dBase file is.Originally posted by KirstenIs there a way to read a simple dBase file using vb.net (2008)?
What have you tried so far to solve your problem?
Have you researched the problem yet and have any questions about what you've discovered so far?
-Frinny -
I tried:
[code=vbnet]
Dim ConString = "Driver={Micros oft Visual FoxPro Driver};UID=;PW D=;SourceType=D BF;" & "SourceDB=h:\ac t\order;Exclusi ve=NO;Backgroun dFetch=No;Colla te=Machine;"
Dim odbcConn As New Odbc.OdbcConnec tion(ConString)
odbcConn.Open()
Dim odbcComm As New Odbc.OdbcComman d
odbcComm.Connec tion = odbcConn
odbcComm.Comman dText = "select * from inv"
Dim Dreader1 As Odbc.OdbcDataRe ader
Dreader1 = odbcComm.Execut eReader
[/code]
And get error on the
odbcConn.Open()
ERROR [IM001] [Microsoft][ODBC Driver Manager] Driver does not support this function:
Originally posted by FrinavaleI'm not sure what a dBase file is.
What have you tried so far to solve your problem?
Have you researched the problem yet and have any questions about what you've discovered so far?
-FrinnyComment
-
I've never used Visual FoxPro before.Originally posted by KirstenI tried:
[code=vbnet]
Dim ConString = "Driver={Micros oft Visual FoxPro Driver};UID=;PW D=;SourceType=D BF;" & "SourceDB=h:\ac t\order;Exclusi ve=NO;Backgroun dFetch=No;Colla te=Machine;"
Dim odbcConn As New Odbc.OdbcConnec tion(ConString)
odbcConn.Open()
Dim odbcComm As New Odbc.OdbcComman d
odbcComm.Connec tion = odbcConn
odbcComm.Comman dText = "select * from inv"
Dim Dreader1 As Odbc.OdbcDataRe ader
Dreader1 = odbcComm.Execut eReader
[/code]
And get error on the
odbcConn.Open()
ERROR [IM001] [Microsoft][ODBC Driver Manager] Driver does not support this function:
I found an awesome resource online though, it's a book titled .NET for Visual FoxPro Devlopers. I think you'd be most interested in Chapter 7: Data Access with ADO.NET. The first section in that chapter talks about the history of ODBC and FoxPro...I think this chapter may help you to understand and fix our problem (there's a lot of information there).
-FrinnyComment
Comment