Private Sub Form_Current()
Dim rs As DAO.Recordset
Set rs = Me.RecordsetClone
If NewRecord Then
rs.MoveLast
Me.编号 = rs!编号
End If
rs.Close
Set rs = Nothing
End Sub
1
Private Sub Form_Current()
Dim rs As DAO.Recordset
Set rs = Me.RecordsetClone
If NewRecord Then
If rs.RecordCount > 0 Then
rs.MoveLast
Me.编号 = rs!编号
End If
End If
rs.Close
Set rs = Nothing
End Sub