Re: What is .DBF, .MDX file?? How to open it to modify??
It's not "Database IV" ... it is "dBase IV" ... it's a database system, like FoxPro, Access, SQL Server, Oracle, etc. If you've got MDAC installed, odds are you've got what you need to read the file in. Try using a connection string something like this:
Re: What is .DBF, .MDX file?? How to open it to modify??
but why I keep having the "Operation not supported on the table that contains data." run-time error when I try to add new column to the .DBF file..
I can open the database and retrieve the data properly using the following... just cannot add new column...
Code:
Dim foldername As String
foldername = "C:\Documents and Settings\Programmer\Desktop\Data"
Conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source= " & foldername & ";Extended Properties=dBase IV;"
Dim sql as string
Dim rs as new ADODB.Recordset
sql="Select * FROM User"
rs.open sql, Conn
If rs.BOF = False Then
xxxxxx
xxxxxx
End If
rs.Close
Re: What is .DBF, .MDX file?? How to open it to modify??
How are you adding the column? Did you ensure that there are no locks on the table (or table is not in use by databound controls) when column is being added?
Re: What is .DBF, .MDX file?? How to open it to modify??
I even use the foxpro driver..
Conn.Open "Driver={Microsoft Visual FoxPro Driver};SourceType=DBF;SourceDB=" & foldername & ";Exclusive=No; Collate=Machine;NULL=NO;DELETED=NO;BACKGROUNDFETCH=NO;"
Re: What is .DBF, .MDX file?? How to open it to modify??
it maybe a limitation of the driver.... once there is data in the table, the table cannot be altered... at least not by using this method. You may have to get a copuy of dBase IV or FoxPro to do the actual table alter.