bigdrewecu
Programmer
ok i have it to where a form starts and the user enters a password which works fine however depending on the user i want to make certain forms read only and others dataentry.
i figured if i coded the first form to store the users name in a global variable and then do an if statement on the form load event with using:
If strUserName = "businessmanager" Then
Me.AllowAdditions = True
Me.AllowDeletions = True
Me.AllowEdits = True
Me.DataEntry = True
ElseIf strUserName = "Admin" Then
Me.AllowAdditions = True
Me.AllowDeletions = True
Me.AllowEdits = True
Me.DataEntry = True
Else
Me.AllowAdditions = False
Me.AllowDeletions = False
Me.AllowEdits = False
Me.DataEntry = False
End If
but for some odd reason it is not working and evaluating to where i can not edit, add new records etc when i log in as admin or businessmanager. any boday have any solutions?
i figured if i coded the first form to store the users name in a global variable and then do an if statement on the form load event with using:
If strUserName = "businessmanager" Then
Me.AllowAdditions = True
Me.AllowDeletions = True
Me.AllowEdits = True
Me.DataEntry = True
ElseIf strUserName = "Admin" Then
Me.AllowAdditions = True
Me.AllowDeletions = True
Me.AllowEdits = True
Me.DataEntry = True
Else
Me.AllowAdditions = False
Me.AllowDeletions = False
Me.AllowEdits = False
Me.DataEntry = False
End If
but for some odd reason it is not working and evaluating to where i can not edit, add new records etc when i log in as admin or businessmanager. any boday have any solutions?