Private Sub Command8_Click(Index As Integer)
'修改
On Error Resume Next
If Command8.Caption = "修改" Then
Command8.Caption = "确认"
Adodc1.Recordset.Edit
DataGrid1.SetFocus
Else
Command8.Caption = "修改"
Adodc1.Recordset.Update
End If
Else
Command8.Caption = "修改"
Adodc1.Recordset.Update
Ado控件没有Edit这个方法,与Dao控件不同如:将 学生信息表 里学号为001的学生年龄修改为18岁Dim mysql as stringmysql = "update 学生信息表 set 年龄 = 18 where 学号 = '001'"myconn.execute mysqladodc1.refresh...