I've got a form with a listbox built on the fields of a table. On the After Update event, I've got this code:
Private Sub lstQueries_AfterUpdate()
Dim LinkCriteria As String
On Error GoTo Err_lstQueries_Afterupdate
LinkCriteria = "qry" & lstQueries.Value
Forms!frmInv.RecordSource = LinkCriteria
DoCmd.OpenForm "frmInv"
Exit_lstQueries_AfterUpdate:
Exit Sub
Err_lstQueries_Afterupdate:
MsgBox Err.Description
Resume Exit_lstQueries_AfterUpdate
End Sub
When I choose from the list box, I get the "Microsoft Office Access can't find form..." message. I actually had this exact proc working until I changed the name of the form...
Any help would be sincerely appreciated! Thanks!
Lori
Private Sub lstQueries_AfterUpdate()
Dim LinkCriteria As String
On Error GoTo Err_lstQueries_Afterupdate
LinkCriteria = "qry" & lstQueries.Value
Forms!frmInv.RecordSource = LinkCriteria
DoCmd.OpenForm "frmInv"
Exit_lstQueries_AfterUpdate:
Exit Sub
Err_lstQueries_Afterupdate:
MsgBox Err.Description
Resume Exit_lstQueries_AfterUpdate
End Sub
When I choose from the list box, I get the "Microsoft Office Access can't find form..." message. I actually had this exact proc working until I changed the name of the form...
Any help would be sincerely appreciated! Thanks!
Lori