Good Day/Night all,
I've learned so much from this forum so far and for that I am grateful. My Tech Support tracker Database is coming together great - I'm very excited to give my coworkers an update on it soon.
Before I get to that point though I have one more function that I absolutely need, and I'm thinking it requres the use of a kind of Global Variable.
I have a login screen that each of my users process through. The goal of this is not actually Database Security, it's Form management - I want to tailor the experience of each of my users depending on who they are and what section they belong to.
The question:
I have a table with everyone's names, and section they belong to (and other values).
When a user has successfully kicked off the login code I need to remember who they are so that future forms they view show only specific values that are related to the section they work in.
Here's the code I have currently - all it does is display a simple message.
Also, once a global variable is established, how would I read it from another form?
Thanks,
~Kit
I've learned so much from this forum so far and for that I am grateful. My Tech Support tracker Database is coming together great - I'm very excited to give my coworkers an update on it soon.
Before I get to that point though I have one more function that I absolutely need, and I'm thinking it requres the use of a kind of Global Variable.
I have a login screen that each of my users process through. The goal of this is not actually Database Security, it's Form management - I want to tailor the experience of each of my users depending on who they are and what section they belong to.
The question:
I have a table with everyone's names, and section they belong to (and other values).
When a user has successfully kicked off the login code I need to remember who they are so that future forms they view show only specific values that are related to the section they work in.
Here's the code I have currently - all it does is display a simple message.
Code:
Private Sub Login_Button_Click()
Dim myUser
myUser = User_Text.Value
If Me.Password_Text = Nz(DLookup("Password", "Personnel_Table", "Name_MMA= '" & myUser & "'"), "N/A") Then
MsgBox "Yay it works. Now go celebrate."
End If
End Sub
Also, once a global variable is established, how would I read it from another form?
Thanks,
~Kit