Jumat, 05 Juni 2020

Re: [MSAccessProfessionals] Updating a list box after new record entry

All,
I got it working!   In the Add Record button procedure I added the method shown in bold below.  When I clicked on the AddRecord button again, the new record showed up!  Hooray!!

Private Sub AddRecord_Click()

On Error GoTo Err_AddRecord_Click

    DoCmd.GoToRecord , , acNewRec

Exit_AddRecord_Click:

Me.List42.Requery

    Exit Sub

 

Err_AddRecord_Click:

    MsgBox Err.Description

    Resume Exit_AddRecord_Click  

End Sub

"When I add a new record to my MSAccess 2010 database on a form with a List Box, the new record does not appear in the list box unless I close the form then re-open it.  Is there a way to have the new record appear in the listbox without going through that?"

_._,_._,_

Groups.io Links:

You receive all messages sent to this group.

View/Reply Online (#115558) | Reply To Group | Reply To Sender | Mute This Topic | New Topic

Your Subscription | Contact Group Owner | Unsubscribe [sugeng.panjalu.access@blogger.com]

_._,_._,_

Tidak ada komentar:

Posting Komentar