We value your feedback.
Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
right now, but it is clearing the information that is added to the second list box.
Private Sub btnAddSelected_Click() Dim frm As Form Dim ctl As Control Dim db As DAO.Database Dim rst As DAO.Recordset Dim i As Variant Set frm = Forms("frm_Act_Enter") Set ctl = frm![lstPrevRpts] Set db = CurrentDb Set rst = db.OpenRecordset("Act_SubTo_Date") For Each i In ctl.ItemsSelected rst.AddNew ' Debug.Print i, ctl.Column(4, i) rst("ActID") = ctl.Column(4, i) rst("ActDate") = Nz(Me!ActDate.Value, Date) rst.Update Next i Me.lstPrevRpts.Selected(i) = False rst.Close Set rst = Nothing Refresh End Sub
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
|Need help with adding Child and Granchild Elements to my XML File in MS Access VBA||11||53|
|How to Check for successful adding a main record in the Main Form and move the Focus to the Sub Form to start adding details?||3||29|
|On form close getting error "the changes you requested to the table were not successfull... duplicate values||3||16|