Klane,
I'm not sure what you mean by a button that "goes to" a subform. A subform
is embedded in the main form, and, if linked by the Project Number would
require no action at all. If you mean that you are opening *another* form
and would like to use the current record as a Filter, use the following code:
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "YourSecondForm"
stLinkCriteria = "[FieldInRecordSourceof2ndForm]=" &
Me![CorrespondingValueFrom1stForm]
DoCmd.OpenForm stDocName, , , stLinkCriteria
If you enable the wizard (View, Toolbox, <toggle on the wand & stars
button>) from form design view, and select Form Operations, Open Form, and
follow the prompts, Access will create the event procedure for you, including
error-handling.
Hope that helps.
Sprinks