|
- Dim rs As New ADODB.Recordset
- Dim intCount As Integer
- Dim ctl As Control
- For Each ctl In Me.Controls
- If ctl.Tag = "a" Then
- If IsNull(ctl) Then
- MsgBox ctl.Name & " Not AllowNull"
- ctl.SetFocus
- Exit Sub
- End If
- End If
- Next
- rs.Open "表2", CurrentProject.Connection, adOpenKeyset, adLockOptimistic
- For intCount = 1 To 12
- With rs
- .AddNew
- .Fields("学号") = Me.学号
- .Fields("月份") = Me.年份 & Format(intCount, "00")
- .Update
- End With
- Next
- rs.Close
- Set rs = Nothing
- Me.表2子窗体.Requery
复制代码原帖由 cangqiong 于 2008-11-25 08:16 发表
帮个忙..
我不会写.. |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?注册
x
|