Results 1 to 6 of 6
  1. #1
    CementCarver's Avatar
    CementCarver is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2013
    Location
    Canada
    Posts
    231

    Who Logged In

    I have an employee table which is read when one of the three users logs into the database. I don't want the persons name who's logged onto the pc. But when I try to set the variable to be = CurrentUser(), I get the user named "Admin", who is not even in the employee table.

    How do I get the name of the person who's logged into the database from the employee table?



    CementCarver

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    How do they log in? CurrentUser() only works with Access built-in security. If you've created your own, you need to save the value yourself, either in a form control, global variable or a table.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    CementCarver's Avatar
    CementCarver is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2013
    Location
    Canada
    Posts
    231
    Yes, I've created my own login screen. How does one populate a global variable to be used later on?

    CC

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    VariableName = YourValue
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    CementCarver's Avatar
    CementCarver is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Feb 2013
    Location
    Canada
    Posts
    231
    Thanks pbaldy....CC

  6. #6
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Happy to help.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

Please reply to this thread with any new information or opinions.

Similar Threads

  1. who's logged in
    By slimjen in forum Forms
    Replies: 2
    Last Post: 03-26-2013, 01:27 PM
  2. restricting access until logged in
    By gbmarlysis in forum Security
    Replies: 1
    Last Post: 02-17-2012, 06:43 PM
  3. Whos Logged in????????
    By george.vniekerk in forum Security
    Replies: 2
    Last Post: 08-26-2011, 12:24 PM
  4. Getusername of currently logged in user
    By nkuebelbeck in forum Access
    Replies: 8
    Last Post: 06-29-2011, 04:06 PM
  5. Currently logged in user into text box
    By ne16428 in forum Security
    Replies: 5
    Last Post: 06-10-2009, 11:46 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums