Filter a form using a command button on another form
Posted
by Shaun
on Stack Overflow
See other posts from Stack Overflow
or by Shaun
Published on 2010-03-30T13:10:49Z
Indexed on
2010/03/30
13:13 UTC
Read the original article
Hit count: 403
access
|ms-access-2003
I have a form with a cmdbutton that at the moment opens another form and shows all records for several types of PartitionStyles and TrimFinishs (486 at present), I need to be able to filter the second form to show only the TrimFinish I need.
Private Sub lbl600SeriesS_Click() Dim stDocName As String Dim stLinkCriteria As String
stDocName = "frmModules"
stLinkCriteria = "Forms!frmModules![TrimFinish] = 1"
DoCmd.OpenForm stDocName, , , stLinkCriteria
End Sub
At the moment it shows only a new record, I know there should be 162 records using 1, what have I missed or done incorrect.
© Stack Overflow or respective owner