MS Access – VBA – Open Form and go to record from unbound List Box

Very clean and simple

Private Sub List0_Click()

    Dim stFormName As String
    Dim stLinkCriteria As String
    
    stFormName = "Form1"
    
    stLinkCriteria = "[ID]=" & Me.List0
    DoCmd.OpenForm stFormName, , , stLinkCriteria
    
End Sub

Author: Mark

Mark Brooks a forty something individual working and living in and around Edinburgh