|
请问如何将订单子窗体中的选定打勾的记录添加到冲压生产排程子窗体中。冲压按钮的代码现是这样的(这样写就全部添加过来了,不合要求):
Private Sub 冲压_Click()
With Me.订单.Form.Recordset
.MoveFirst
For X = 0 To .RecordCount - 1
Me.冲压生产排程.SetFocus
DoCmd.GoToRecord , , acNewRec
Me.冲压生产排程.Form![订单号] = Me.订单.Form![订单号]
Me.冲压生产排程.Form![瓶身] = Me.订单.Form![瓶身]
Me.冲压生产排程.Form![选择] = -1
Me.冲压生产排程.Form![数量] = Me.订单.Form![订单数]
Me.订单.Form![选择] = -1
.MoveNext
Next
End With
MsgBox Me.订单.Form.Recordset.RecordCount & "条记录追加成功!", vbInformation, "结果提示"
End Sub |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?注册
x
|