C
Chris
Based on some good advice I received, I wanted to recode my form which has
multiple subforms on various tab controls to only activate the subforms when
the tab is selected.
I wanted to make a generic procedure to do this for the various subforms,
but am getting confused how to pass the subform identifier to the routine.
What am I doing wrong? Trying to set up something like the below, which
would wake up a subform control named "Dftlog" with a source object of
"fDFTLog".
WakeUpSubform(what do I pass here?, "fDFTLog")
Private Sub WakeUpSubform(ctl As what must this be dimensioned as?,
strSrcObj as String)
On Error GoTo Err_Routine
If Not ctl.SourceObject <> "" Then
ctl.SourceObject = strSrcObj
ctl.Visible = True
End If
Endsub
multiple subforms on various tab controls to only activate the subforms when
the tab is selected.
I wanted to make a generic procedure to do this for the various subforms,
but am getting confused how to pass the subform identifier to the routine.
What am I doing wrong? Trying to set up something like the below, which
would wake up a subform control named "Dftlog" with a source object of
"fDFTLog".
WakeUpSubform(what do I pass here?, "fDFTLog")
Private Sub WakeUpSubform(ctl As what must this be dimensioned as?,
strSrcObj as String)
On Error GoTo Err_Routine
If Not ctl.SourceObject <> "" Then
ctl.SourceObject = strSrcObj
ctl.Visible = True
End If
Endsub