setting a subforms dataseet programatically.

C

Cyberwolf

Currently I have a form that has its record source set programatically based
on a check box on anothyer form Code:

stDocName = "frm:JCPTB"
DoCmd.OpenForm stDocName, acFormDS, , stLinkCriteria

Select Case OptCo

Case 1
Forms![frm:JCPTB].RecordSource = "JCPBS Current TB"

Case 2
Forms![frm:JCPTB].RecordSource = "JCPFT Current TB"

Case 3
Forms![frm:JCPTB].RecordSource = "JCPKB Current TB"

Case 4
Forms![frm:JCPTB].RecordSource = "JCPRM Current TB"

End Select

At this point this is a partent form only. I am tryng to make it a parent
child form with the data from the aboce case select to appear in the subform.
Any suggestions?

TIA
 
Top