Splitting Database With Different Front Ends (1 Viewer)

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Hello,


I am getting close to the design of my database (Access 2013) and soon will be splitting.


I would appreciate if someone has advice on the proper way to do this. I would like to have different versions of the front ends for each user for instance:


Version #1 full administrator rights
Version #2 Creating new records at form level and printing reports
Version #3 read only version at form level


There may be multiple copies of Version #2 and Version #3.


Thank you kindly for your help
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 09:56
Joined
Jul 9, 2003
Messages
16,243
I would avoid having three different versions, I would design one version that has three modes of operation. Proliferation of front-ends will become a nightmare, I assure you!
 

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Thank you Uncle Gizmo due to my lack of knowledge and my frustrations I have steered many away from helping me. I cannot get my form partially locked from others is why I am considering different front ends.


My current older database that I created has different front ends that has been effective for the last 5 years.


I am creating this new one to hopefully be more efficient.
 

NauticalGent

Ignore List Poster Boy
Local time
Today, 05:56
Joined
Apr 27, 2015
Messages
6,280
I would avoid having three different versions, I would design one version that has three modes of operation. proliferation of front-ends will become a nightmare I assure you!

Emphatically agree with AWFs favorite uncle. There are better ways to impose restrictions on certain users. If you choose to go this way, sing out and you will be showered with the many options to do just that...
 

bdra2778

Registered User.
Local time
Today, 02:56
Joined
Feb 14, 2019
Messages
34
Check this small example, it will give you an idea to create a single Front-End for different types of restrictions according to the type of users.
 

Attachments

  • User Restriction.zip
    149.8 KB · Views: 76

Solo712

Registered User.
Local time
Today, 05:56
Joined
Oct 19, 2012
Messages
828
Thank you Uncle Gizmo due to my lack of knowledge and my frustrations I have steered many away from helping me. I cannot get my form partially locked from others is why I am considering different front ends.


My current older database that I created has different front ends that has been effective for the last 5 years.


I am creating this new one to hopefully be more efficient.

Hi,
Usually, the way to deal with different access rights of users, is by having a table with users and their access levels or profiles that give them right to see forms/reports and perform operations. The users log in and their credentials are saved for the session. Then they are referenced when user indicates some activity that is restricted. That way a single front-end will do. The thing with multiple front ends is that the application becomes more difficult to maintain across a number of FE files. Also when people move around, or change their job, you may have to move "their" front end with them, which again means more admin work. It's much easier to maintain one front end with defined access rights to different users. Then, you are updating the FE only once, and all you have to do when people are re-assigned, is to change their user level or profile.

Now, having said that, there are situation where multiple front ends are warranted. I have done a project, a factory application, where there were several "kiosks" (dedicated workstations) on the floor, each assigned specific tasks and managing different inventory of parts and semi-finished products for a department. Management wanted to continue to capture the work process based on previous Excel sheets that were tailor-made for each of the stations. After 8 years the Access app still works without a hitch.

Best,
Jiri
 

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Thanks everyone I thought I was the one asked to sign out.

I will follow your excellent suggestions in the morning.
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 04:56
Joined
Feb 28, 2001
Messages
26,996
Concur with Jiri and the others who advise single, smarter front-end. As I have stated many times before, in Access there are very few NEVER cases - but quite a few "hardly ever" cases. Multiple FE files to a single BE is one of those "Never... well, hardly ever" cases.

Billy, my advice is to divide this beast in order to conquer it. To do this, you will need to use the SEARCH feature of this form to look for articles on "User Roles." This will lead you into discussions of how to identify and remember facts about your logged-in user for the duration of the session. It will also lead you to different strategies about how to make a form "know" enough about its user to "do the right thing." The only warning I will give you is that there are a LOT of different ways to skin this cat, enough to become more than a little confusing and bewildering. Do some reading, then pick a mode of attack on your problem and come back to discuss it with us.

If you have not used it before, this forum's SEARCH feature is in the thin blue menu-bar ribbon near the top of the page. SEARCH is 3rd from the right in that ribbon.
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 09:56
Joined
Jul 9, 2003
Messages
16,243
If you wish then I will leave

Ah! all becomes clear, you weren't asked to leave, what John actually said was "If you choose to go this way, sing out and you will be showered with the many options" I reckon you read that as "sign out" not "sing out"?
 

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Yes it was my misunderstanding. Things just haven't been going well for me lately.
 

NauticalGent

Ignore List Poster Boy
Local time
Today, 05:56
Joined
Apr 27, 2015
Messages
6,280
Yes it was my misunderstanding. Things just haven't been going well for me lately.

Ah yes. dealing with Access can be a real challenge and dealing with the many “personalities” here at AWF can be a real pain at times too.

There were times I felt as if I was almost being attacked because I asked a question in a certain way. Best advice I can give is push through. The rewards are great, trust me.

Thick skin helps too...some of these members are brutal!
 

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Hi,


I did some reading and watched a few videos.



How about this idea?


I have a main form AFRs that I can have different versions:


1) Administrator - full access
2) Clerk - Data entry all fields and print reports
3) Technician - Limited data entry some fields others locked and print reports
4) Research - read only



Then have user logins that will direct them to correct form with the properties in place.


I would like comments please on this method.



Thank you
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 04:56
Joined
Feb 28, 2001
Messages
26,996
That is one approach. To make that one work, you need a dispatcher or switchboard form that "knows" who the user is and only offers one option - but the user doesn't realize that underneath the button to launch the correct form, there is some logic in the button-click routine that decides what form they get.

For example, if you have a user table and have already determined the person's role via some lookup when the DB was launched:

Code:
Private Sub LaunchAFR_Click()

SELECT CASE UserRole
    CASE Admin
        DoCmd.OpenForm "AFR_Adm"
    CASE Clerk
        DoCmd.OpenForm "AFR_Clrk"
    CASE Tech
        DoCmd.OpenForm "AFR_Tech"
    CASE Research
        DoCmd.OpenForm "AFR_Res"
    CASE ELSE
        MsgBox "You are not allowed to use this form", vbOKOnly, "Access Denied"
End Select
End Sub

The above is shot-from-the-hip "Air Code" with no infrastructure shown, only to clarify the concept. But you should be able to figure out where it gets everything.

I think it is crucial in ANY db app that has such differentiation requirements that you very scrupulously (or even unscrupulously) prevent your users from seeing anything other than your controlling form. That is true whether it is a true switchboard or dispatcher or some home-grown thing that has the same effect. Because of course, if you are not so thorough in such treatment, your users will go to the one that gives them the ability to do what they WANT to do, rules be damned.

In case you are unsure about this, the correct reading topic for this forum is "Securing a database."

EDIT: A thought occurred to me after looking at this. Doing four forms rather than one smart form works - but in that case, build the one that can do everything first. Then go back and copy it to the other three forms and do a little surgery on the ones with lesser abilities. Take out or disable the parts you don't want the less powerful users to see.

The smart-form alternative is that everything is enabled on the form until the Form_Load event fires - at which point based on role, you turn off the features that user shouldn't see.
 
Last edited:

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Thank you Doc Man I will get to work fine tuning the main form and then make copies of each will have different properties.


After this I will figure out security levels for the users as to which forms to let them see from my Switchboard form.


I am attaching my latest file so you can see if you want.


I really appreciate everyone here.
 
Last edited:

Mark_

Longboard on the internet
Local time
Today, 02:56
Joined
Sep 12, 2017
Messages
2,111
One piece of advise if you DO go with different forms for different roles, do so by talking to the people who will be using the forms FIRST to find out what order you really need to have the fields in. This goes a long way to avoiding "I want to use the other one".
 

billgyrotech

Banned
Local time
Today, 04:56
Joined
Apr 18, 2013
Messages
258
Thanks Mark this new database has the same form layout as the one they were using for the past 5 years. It has issues is why I have started over.


They should jump right in without any training needed.
 

Users who are viewing this thread

Top Bottom