dBase VFP OleDb or ODBC Drivers

J

JeffP@Laptop

Error at Open() - Driver does not support this function

I've tried the OLEdb driver with similar failure, different error but
basically I cannot Open using the Foxpro driver(s)

Any clues?

..... snipit

Dim sDB As String = "c:\Apps\R2M\Data"
Dim sConn As String = "Driver={Microsoft Visual Foxpro
Driver};SourceType=DBC;SourceDB=" & sDB & ";"
Dim Cnn As New OdbcConnection(sConn)

'Driver does not support this function...
Cnn.Open()

Dim sCmd As String = "set Exclusive on;select * from items;pack"
Dim dbCmd As New OdbcCommand(sCmd, Cnn)
dbCmd.ExecuteNonQuery()

TIA

JeffP.....
FYI this works and inserts the data into the items.dbf datafile.
..... snipit
Dim sDB As String = "c:\Apps\R2M\Data"
Dim sConn As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=" & sDB & ";Extended Properties=dBASE 5;"
Dim cnn As New OleDbConnection(sConn)
Dim sCmd As String = "insert into items values(1001 ,'Tower Spat'
,'061001' ,13.64 ,26.99)"
Dim da As New OleDbDataAdapter(sCmd, cnn)
Dim ds As New DataSet
da.Fill(ds)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,043
Latest member
CannalabsCBDReview

Latest Threads

Top