(Using Access97)
I want to call this standard module sub from various form modules:-
When I call it from a main form, this works fine:-
This effectively makes the second line of the standard module:-
When I call from a subform, I need the line to effectively give me:-
I can't find any combination that I can type into the NewBtn("?????") brackets on the subform module which doesn't give me the error msg "can't find the form 'MyForm....etc'".
You will make an old man very happy if you can enlighten me.
Appreciate any replies.
John
I want to call this standard module sub from various form modules:-
Code:
Sub NewBtn(FormName As String)
Forms(FormName).BtnOK.Enabled = True
Code:
Private Sub BtnNew_Click()
NewBtn ("MyForm")
Code:
Forms!MyForm.BtnOK.Enabled = True
Code:
Forms!MyForm.MySubForm.Form.BtnOK.Enabled = True
You will make an old man very happy if you can enlighten me.
Appreciate any replies.
John
Last edited: