I have rewritten some apps from Paradox
to VB6 but one problem I have is, I have
not yet found a way to show deleted records
on dBase IV tables in VB. Does anyone know
if this is possible?
Thanks for any help in advance.
Printable View
I have rewritten some apps from Paradox
to VB6 but one problem I have is, I have
not yet found a way to show deleted records
on dBase IV tables in VB. Does anyone know
if this is possible?
Thanks for any help in advance.
I don't know about Dbase but in FoxPro (which is Xbase) you can do something like this.
This allows me to see the deleted records.Code:cnnYourConnect.Execute "Set Deleted Off"
if you want to set it back.
Code:cnnYourConnect.execute "Set Deleted On"
I receive an error : Expected SQL Statement.
Am I not doing it right?
How are connecting to your database? (code?)
Public Sub first()
Set cnConn = New ADODB.Connection
Set cmdConn = New ADODB.Command
Set rsConn = New ADODB.Recordset
cnConn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=f:\users\mdoss\pdcdata\data;Extended Properties=dBase IV;Persist Security Info=False"
Set cmdConn.ActiveConnection = cnConn
cmdConn.CommandText = "filectrl.dbf"
cmdConn.Execute "Set Deleted Off"
Set rsConn = cmdConn.Execute(adCmdTable)
rsConn.MoveFirst
While Not rsConn.EOF
x = x + 1
rsConn.MoveNext
Wend
MsgBox Str(x)
End Sub
I changed the execute to run on the command,
I do not receive any error messages, but it
still does not show deleted records.
I don't know how to see the deleted records using the Dbase driver, but if want you could use the Visual FoxPro Driver and build your connect string like so:
Hope this helps.Code:strConnect = "DSN=Visual FoxPro Tables;UID=;"
strConnect = strConnect & "PWD=;SourceDB=f:\users\mdoss\pdcdata\data;"
strConnect = strConnect & "SourceType=DBF;Exclusive=No;"
strConnect = strConnect & "BackgroundFetch=Yes;"
strConnect = strConnect & "Collate=Machine;Null=Yes;Deleted=No;"
cnConn.Open strConnect
[Edited by dcarlson on 12-07-2000 at 11:49 AM]
Still failing.
Cannot find installable ISAM.
You may need to install the VFP Driver. Check your ODBC datasources for the Microsoft Visual FoxPro Driver. I think you can install it with the Visual Basic or Visual Studio CD.