Hi everyone, i have this vbs code:
And it works very well, but the changes into the table not are made "on the fly" i mean, is necessary a kind of "refresh" in the table in order the changes be displayed ( for example if i close and open the database file the changes are well updated). I wonder if exist a trick or some way to refresh automatically the data inserted
Thanks in advance
Code:
Const adOpenStatic = 3
Const adLockOptimistic = 3
Set objConnection = CreateObject("ADODB.Connection")
Set objRecordSet = CreateObject("ADODB.Recordset")
objConnection.Open _
"Provider = Microsoft.Jet.OLEDB.4.0; " & _
"Data Source = C:\Path\base.mdb"
objRecordSet.Open "INSERT INTO TemporalAd (Maquina, Codigo, IdArticulo, Detalle, Cantidad, PUnitario, IdUnidad)" & _
"VALUES ('1', '11234','2', 'Impresion Color', '1','25','2')", _
objConnection, adOpenStatic, adLockOptimistic
objRecordSet.Open _
"Update Temporal " & _
"Set Adicionales = (1)", _
objConnection, adOpenStatic, _
adLockOptimistic
And it works very well, but the changes into the table not are made "on the fly" i mean, is necessary a kind of "refresh" in the table in order the changes be displayed ( for example if i close and open the database file the changes are well updated). I wonder if exist a trick or some way to refresh automatically the data inserted
Thanks in advance