Public Sub ADOUpdate()
Dim rs As ADODB.Recordset
Dim strSQL As String
Set rs = New ADODB.Recordset
strSQL = "SELECT CompanyName, Address, City FROM tblCompany WHERE (CompanyName = 'Liams Diner')"
rs.Open strSQL, CurrentProject.Connection, adOpenKeyset, adLockOptimistic
With rs
!CompanyName = "Diner"
.Update
End With
rs.Close
End Sub
|