Ole provider connection String

  • Thread starter Thread starter neogeo
  • Start date Start date
N

neogeo

I am trying to read a DBF from ASP.NET page, this is the code that I a
using.....

Dim myConn As Ne
OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Dat
Source=C:\capitaltest\data;Expanded Properties=dBase IV")

myConn.Open()

Dim myCommand As New OleDbCommand("Select * from stock", myConn)

Dim reader As OleDbDataReader
reader = myCommand.ExecuteReader()
myConn.Close()

I get the following error ->>> Could not find installable ISAM

If the code is changed to the following...
Dim myConn As Ne
OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Dat
Source=C:\capitaltest\data\stock.dbf;")
myConn.Open()

Dim myCommand As New OleDbCommand("Select * from stock", myConn)

reader = myCommand.ExecuteReader()
myConn.Close()

I get this type of error ->>>>
Unrecognized database format 'C:\capitaltest\data\STOCK.DBF'

Can anyone please help!!


-
neoge
 
Hello Neogeo,
neogeo said:
I am trying to read a DBF from ASP.NET page, this is the code that I am
using.....

Dim myConn As New
OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=C:\capitaltest\data;Expanded Properties=dBase IV")

myConn.Open()

Dim myCommand As New OleDbCommand("Select * from stock", myConn)

Dim reader As OleDbDataReader
reader = myCommand.ExecuteReader()
myConn.Close()

I get the following error ->>> Could not find installable ISAM

If the code is changed to the following...
Dim myConn As New
OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=C:\capitaltest\data\stock.dbf;")
myConn.Open()

Dim myCommand As New OleDbCommand("Select * from stock", myConn)

reader = myCommand.ExecuteReader()
myConn.Close()

I get this type of error ->>>>
Unrecognized database format 'C:\capitaltest\data\STOCK.DBF'

Can anyone please help!!!

Read
http://dbforums.com/arch/212/2002/11/556668



mfg simon g.
 
Check in your Registry if you find following key.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Jet\4.0\ISAM Formats\dBase IV

If not, then dBase IV Provider is not installed.

Best Regards,

Luqman
 
Back
Top