Enable / Disable MS Access Button

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sinvier
    New Member
    • Nov 2014
    • 2

    Enable / Disable MS Access Button

    I need help with a vba code to only allow people who are logged in as Admin to be able to open a button called Manage Users and at the same time grey it out for people who log in as User. Thanks in advance for the help!

    MS ACCESS 2013
  • Seth Schrock
    Recognized Expert Specialist
    • Dec 2010
    • 2965

    #2
    Do you mean logged into Windows as Admin or do you have a login system for your database?

    Comment

    • twinnyfo
      Recognized Expert Moderator Specialist
      • Nov 2011
      • 3664

      #3
      sinvier,

      Take a look at this thread and see if it provides you any additional guidance (User Permissions in MS Access).

      Comment

      • sinvier
        New Member
        • Nov 2014
        • 2

        #4
        I figured it out, thanks though and Twinnyfo that was a good read. Thanks.

        If strCBOPass = strPassword And strUsertype = "Administra tor" Then

        DoCmd.Close acForm, Me.Name
        DoCmd.OpenForm "Main_Form"

        ElseIf strCBOPass = strPassword Then

        DoCmd.Close acForm, Me.Name
        DoCmd.OpenForm "Main_Form2 "

        Comment

        Working...