Results 1 to 9 of 9
  1. #1
    Join Date
    Feb 2009
    Posts
    12

    Unanswered: User Authentication

    I have a form that pulls employee information from one table, after selecting a name from a drop down, and there is a child form for data entry to another table. I need to design a data authentication piece that will allow an employee to select their name (upon registration) and after login will only show them their files. I have attached a copy of the database for reference. I am using access 2003 ... they will be upgrading this month or next, but I could not wait.

    Thank you so much for taking the time to help me out! You guys have always been such a valuable resource when I've hit a brick wall.
    Attached Files Attached Files

  2. #2
    Join Date
    Jun 2011
    Location
    Inside your mind
    Posts
    297
    I'm at work, and for some reason can never unzip files here, so I'm a little confused by what you mean by 'files'...

    Are they sets of notes? Or physical .txt files? Or what...

    I'm assumig they're just bits of data held in a table somewhere?
    Looking for the perfect beer...

  3. #3
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    have you considered using the network logon as the authentication tool. to find out more either google dev ashish API or look in the code bank for this forum.
    I'd rather be riding on the Tiger 800 or the Norton

  4. #4
    Join Date
    Feb 2009
    Posts
    12
    @kez sorry sorry ... it wouldn't allow me to attach the mdb ... by files i mean individual entries in the table.

    @healdem ... i have looked at it ... but it's a smidge beyond me. i will investigate further.

  5. #5
    Join Date
    Feb 2009
    Posts
    12
    @healdem ... i did find the code you were suggesting ... i have created the module ... but what do i do with it from there?

  6. #6
    Join Date
    Jun 2011
    Location
    Inside your mind
    Posts
    297
    So you want a form with 'Username' and 'Password', along with a submit button.

    Then provided their details are correct, their personal data (i.e. the table contents associated with their username) are brought up on screen.

    Is that correct?

    If so, and provided you're using .mdb files and security isn't a major concern, then personally, I would create a table with two columns; 'Username' and 'Password', which are used as a reference for checking peoples logins, then have an SQL statement that brings up all the 'files' associated with the username.

    The reason I mentioned security and the .mdb filetype is so you can use user-level security to control access to the the user/pass table.
    Looking for the perfect beer...

  7. #7
    Join Date
    Feb 2009
    Posts
    12
    @kez yes, I'm in the process of creating that form as we speak ... but don't i need some sort of registration form? to establish the agent's identity? ... i do think i can use windows authentication ... i just don't know how.

  8. #8
    Join Date
    Jun 2011
    Location
    Inside your mind
    Posts
    297
    Yup, a form for registration and a form for logging in.

    Registration form would use an INSERT INTO statement, with some vba checks to ensure database integrity (i.e. no duplicate usernames, password lengths, etc.)
    Login could just use a SELECT statement.

    Ideally you should use windows authentication if you can, although unfortunately I haven't had experience with that so can't offer any assistance.
    Looking for the perfect beer...

  9. #9
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    as API: Get Login name suggests
    copy the function fOSUserName (and anyother functioins you find on that site
    create a new code module in your Access project / file / mdb
    paste the function fOSUserName (and any others yoiu find that are usefull)
    when you need to retrieve the netwrok logon
    call the function

    eg
    Code:
    myUserName = fOSUserName 
    if isnull( myUserName) thenb
      'oh shaggy null username suspect the network is borked
    else
      'dosomething
    endif
    no need foer a user to enter a userid + password
    no need for you to maintian your own userid table, no need fo ryou to design,test and develop your user account code
    no need to force the user to creatre a new passowrd or think of devious rules to workout whether a password is legit.

    the only thin you may have rto do is assign the network logon to an Access user group in the security wizard / workgroup file
    I'd rather be riding on the Tiger 800 or the Norton

Posting Permissions

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