Results 1 to 8 of 8
  1. #1
    Star Lounger
    Join Date
    Jul 2002
    Location
    Petersburg, Virginia
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Using PC logon (XP sp2)

    I currently use forms to collect the User's logon and password. Is there a way to use the User's PC logon to identify him/her for purposes of filtering records, etc.

  2. #2
    2 Star Lounger
    Join Date
    Sep 2001
    Location
    Wellington, Wellington, New Zealand
    Posts
    181
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using PC logon (XP sp2)

    Hi

    I presume you are a) talking about security and [img]/forums/images/smilies/cool.gif[/img] do not wish to use Access security feature. There are number of ways to do this. In some of my DBs I created a table containing user names and logon names, and assign them various user rights (yes/no fields). You can then use this information to compare against the captured PC user logon to determine what they can and can not do. This can be done by using a function which can be called from forms etc.

    If this is not what you are wanting, then more details are required.

    Regards
    WTH

  3. #3
    Star Lounger
    Join Date
    Jul 2002
    Location
    Petersburg, Virginia
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using PC logon (XP sp2)

    Your assumptions are correct, and I'm currently doing something similar to what you describe. What I would LIKE to do is "capture the user's PC logon" and compare that against field contents in tbl_Users rather than require the user to type in a separate logon and password for the database. Currently:

    tbl_Users contents:
    username Password MainForm
    kitty pass1 frm_main
    tom pass2 frm_maindept

    frmLogon opens at Startup, user enters name, it looks into tbl_Users to find matching name. If successful, frmPassword is opened, user enters password, if match found in tbl_Users main form is opened (different forms for different users).

  4. #4
    Super Moderator
    Join Date
    Aug 2001
    Location
    Evergreen, CO, USA
    Posts
    6,623
    Thanks
    3
    Thanked 60 Times in 60 Posts

    Re: Using PC logon (XP sp2)

    It seems to me you are going to a good deal of work to avoid using Access User Security. If you want to open different forms for different users all you have to do is set up security but not give users a password (other than Admin), and then check the userid with CurrentUser() to see which form to open. The advantage with user security is that you can then block users from certain functions if you need to, and only allow special users (yourself) to access the design of forms, etc.
    Wendell

  5. #5
    4 Star Lounger SteveH's Avatar
    Join Date
    Jan 2001
    Location
    Chelsea, Gtr London, United Kingdom
    Posts
    587
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using PC logon (XP sp2)

    This code from The Access Web will do what you want for capturing the User's Log-In name.
    Steve H
    IT Lecturer/Access Developer
    O2K SR3/O2010; Win7Pro

  6. #6
    Star Lounger
    Join Date
    Jul 2002
    Location
    Petersburg, Virginia
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using PC logon (XP sp2)

    That's what I'm looking for. Thanks!

  7. #7
    Star Lounger
    Join Date
    Jul 2002
    Location
    Petersburg, Virginia
    Posts
    54
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using PC logon (XP sp2)

    You are probably right, but I don't have Access Security skills. Accessing username seemed simpler. Code has been provided.

  8. #8
    Super Moderator
    Join Date
    Aug 2001
    Location
    Evergreen, CO, USA
    Posts
    6,623
    Thanks
    3
    Thanked 60 Times in 60 Posts

    Re: Using PC logon (XP sp2)

    The basics aren't really that hard - you might take a look at the Security Tutorial on our website. It's an introduction, but enough to get you started, and has links to all the gory details.
    Wendell

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •