A
Arvin Villodres
I'm trying to call a function from the class module
whenever I try to
open a form. But somehow the form that was opened does not
perform the
function I'm trying to call. My code goes like this:
*The function I'm trying to call.
Public Function Identify()
If txtUserName = "Administrator" Then
me.AllowEdits = True
Else
me.AllowEdits = False
End If
End Function
*The code in the form that is being opened. This form has
a text box (txtUserName)identifying the user.
Private Sub Form_Open(Cancel As Integer)
hello
End Sub
When I try to debug it the note that is being seen on the
txtUserName of the function Identify
when the focus is on it says "txtUserName = Empty"
Please help me with this one. I'm still not that familiar
with class Modules. or calling a function.
Thanks for the help.
Arvin Villodres
whenever I try to
open a form. But somehow the form that was opened does not
perform the
function I'm trying to call. My code goes like this:
*The function I'm trying to call.
Public Function Identify()
If txtUserName = "Administrator" Then
me.AllowEdits = True
Else
me.AllowEdits = False
End If
End Function
*The code in the form that is being opened. This form has
a text box (txtUserName)identifying the user.
Private Sub Form_Open(Cancel As Integer)
hello
End Sub
When I try to debug it the note that is being seen on the
txtUserName of the function Identify
when the focus is on it says "txtUserName = Empty"
Please help me with this one. I'm still not that familiar
with class Modules. or calling a function.
Thanks for the help.
Arvin Villodres