dBase file in VB.Net ?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Kirsten
    New Member
    • Feb 2008
    • 19

    dBase file in VB.Net ?

    Is there a way to read a simple dBase file using vb.net (2008)?
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    Originally posted by Kirsten
    Is there a way to read a simple dBase file using vb.net (2008)?
    I'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?

    -Frinny

    Comment

    • Kirsten
      New Member
      • Feb 2008
      • 19

      #3
      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 Frinavale
      I'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?

      -Frinny
      Last edited by Frinavale; Feb 12 '08, 09:49 PM. Reason: Added [code] tags

      Comment

      • Frinavale
        Recognized Expert Expert
        • Oct 2006
        • 9749

        #4
        Originally posted by Kirsten
        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:
        I've never used Visual FoxPro before.
        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).

        -Frinny

        Comment

        Working...