Quantcast
Channel: VBForums - CodeBank - Visual Basic 6 and earlier
Viewing all articles
Browse latest Browse all 1450

VB6-Adodc1.Recordset.ActiveConnection.Execute Sql

$
0
0
Code:

Adodc1.ConnectionString = "provider=microsoft.jet.oledb.4.0;data source=" & App.Path & "\test.mdb"
Adodc1.RecordSource = "select * from usertable"
Adodc1.Refresh

Adodc1Execute "UPDATE Usertable SET Usertable.[Password] = 'abc2" & Now & "' WHERE UserName='user1'"

Function Adodc1Execute(Sql As String)
'On Error GoTo err
    Adodc1.Recordset.ActiveConnection.Execute Sql
 
    Adodc1.Recordset.ActiveConnection.Close
    Adodc1.Refresh

'    Adodc1.Refresh
'    DataGrid1.Refresh
'    Adodc1.Refresh
    Exit Function
err:
    MsgBox err.Description
End Function


Viewing all articles
Browse latest Browse all 1450

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>