Try the following sample (you will need of an MDB file). Now remove the comment of the ACTION clause and you will notice that the LDB file is not deleted anymore. Why?
EMG
#include "Fivewin.ch"
#define adOpenForwardOnly 0
#define adOpenKeyset 1
#define adOpenDynamic 2
#define adOpenStatic 3
#define adLockReadOnly 1
#define adLockPessimistic 2
#define adLockOptimistic 3
#define adLockBatchOptimistic 4
#define adUseNone 1
#define adUseServer 2
#define adUseClient 3
FUNCTION MAIN()
LOCAL oRs := CREATEOBJECT( "ADODB.Recordset" )
oRs:Open( "SELECT * FROM Clienti", "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=clienti.mdb", adOpenKeyset, adLockOptimistic )
TEST( oRs )
oRs:Close()
oRs = NIL
RETURN NIL
STATIC FUNCTION TEST( oRs )
LOCAL oDlg
DEFINE DIALOG oDlg
@ 1, 1 BUTTON "";
// ACTION oRs
ACTIVATE DIALOG oDlg;
CENTER
RETURN NILEMG