Page 1 of 2 12 LastLast
Results 1 to 15 of 16
  1. #1
    Join Date
    Nov 2010
    Posts
    8

    Prevent Users from Deleting Records

    Hello,


    I am very new to access but have created databases in other software. I'm creating a really simple database to house documents. In my other software, I created accounts and privileges for my users to prevent them from doing any damage. I would like to do the same here. All I really need is and Admin account for me and a guest account for everyone else. The guest account can search, filter and export but can't add, delete or change information. How do I do this? I read one of those Access for dummy books and saw nothing about accounts or preventing users from doing damage. Any suggestions on better reading material or how to do this would be greatly appreciated.

    Thanks

  2. #2
    NTC is offline VIP
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    2,392
    one does this by keeping the user within the Form - and not getting directly into the table. Within the form properties one can lock or unlock fields. one can also do this at the individual control property also.

    a simple way is to create a form with locked fields - and users of a certain 'class' as dictated by their log in info - then get directed to this form; while other users get directed to a form that is unlocked.

    hope this helps.

  3. #3
    Join Date
    Nov 2010
    Posts
    8
    Thanks NTC, I got the form set up with the fields locked. Since the user-level security I was looking for appears to no longer exist in Access 2007, I'm going to try to hide the tables from my users in the Navigation Pane. That way only the forms are visible. I'm not sure how to direct users at log in because I believe accounts are also only available in Access 2003. If I'm wrong please let me know.

  4. #4
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    split the database. the tables are stored on the backend and merely linked to the front end. then disable the navigation pane and keep them in a form the whole time. they wont be able to touch your tables.

  5. #5
    Join Date
    Nov 2010
    Posts
    8
    The database is going to sit on a shared drive meaning the front end and backend would sit on a shared drive. The users could just open the backend and mess up the tables there.

  6. #6
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    My idea was to prevent accidental harm to the data. If you're trying to prevent against malicious harm to your data, I think you are better off trying to edit the user instead of the database. Access really isnt designed to be put on lockdown to prevent this kind of stuff.

  7. #7
    Join Date
    Nov 2010
    Posts
    8
    I'm not trying to prevent against malicious harm just accidental. I've found that even though you believe it impossible for a user to make such a stupid mistake, they will do it within a matter of minutes.
    What I want is when the file is opened to run a Macro that identifies the user as Admin or Guest. If it is Guest then they are given only the two forms I created. If it is me (Admin) I want access to everything. My users only need to search the data, while I perform data entry. I've tried manipulating the Navigation Pane and hiding things so that the users only see the two forms. This works but it would be a pain for me to undo and redo these restrictions so I can perform data entry. Also if I can do it then so can the users.

  8. #8
    NTC is offline VIP
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    2,392
    The FE needs to be on each's desktop. The FE can not be shared. With the navigation pane disabled - they will have no direct access to tables.

    While User Level Security is indeed now gone, most do not miss it. It is relatively simple to roll your own. Have a UsersTable with a value assigned to each's log in - and if they are value X then have your opening argument of the form point at the locked form. If they are value Z then your opening argument points to the unlocked form. (or you could make visible/not visible differing Open button on the form)...

    a combobox sourced on the UserTable will suffice - so they select themselves. have an unbound box for the PW...then compare it to the PW in their UserTable... then go from there.

    Hope this helps.

  9. #9
    Join Date
    Nov 2010
    Posts
    8
    How do you force a log in?

  10. #10
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    make a login form that opens when the db is opened. make it maximized and remove the close button

  11. #11
    Join Date
    Nov 2010
    Posts
    8
    Ok, looks like this simple database is going to be a lot more work than I anticipated. Thanks for all your help. Hopefully I'm on the right track now.

  12. #12
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    to be honest, you really dont need the admin and user accounts. if you split the DB, put the front end on the users desktops and the backend on your shared drive. if you disable the navigation pane and have your forms in order, the users wont be able to change the data in the tables.

  13. #13
    Join Date
    Nov 2010
    Posts
    8
    The database has to sit on a controlled network, so I can't send it to their desktops. That is why I'm forced to use Access, the software is already on that network. If I was allowed to use the database software I normally design with then I would have had the thing built in about 30 minutes.

  14. #14
    TheShabz is offline Court Jester
    Windows XP Access 2003
    Join Date
    Feb 2010
    Posts
    1,368
    the database DOES sit on a controlled network. the backend IS the database. the FE is nothing more than an interface. it's like when you have a website with a database. the FE is just the php script that interfaces with the database on the backend. there are no tables stored on the FE.

  15. #15
    Join Date
    Nov 2010
    Posts
    8
    The front end also has to sit on the controlled network, so there is no point in splitting the database if both have to be in the same place.

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. deleting records
    By radicalrik in forum Queries
    Replies: 2
    Last Post: 07-14-2010, 03:10 PM
  2. deleting records off a subform
    By jamin14 in forum Programming
    Replies: 10
    Last Post: 04-22-2010, 08:47 PM
  3. Replies: 3
    Last Post: 03-25-2010, 12:31 PM
  4. Restart auto number after deleting records
    By P5C768 in forum Database Design
    Replies: 1
    Last Post: 09-11-2009, 02:07 PM
  5. Problem Deleting Records with ADO
    By bdicasa in forum Programming
    Replies: 0
    Last Post: 08-21-2008, 09:27 AM

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