How to Set User Security Without a Login Form Access Database

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone welcome back to my video tutorial for microsoft access on previous video i will show you how to create a login form like this one log in like using user username and password one two three and in the to domain menu however in this video i will show you how to set user security without a login form or how to use the computer user to log into the database without a login form that means we don't need this we don't need this login form i will just delete that okay we don't need that in this how to let's go back to the user table that the previous video we set up this user table we have the username and the password field this used for the login form but in this video we don't need that we can just delete that password fill out okay the username we still need that however we're gonna change to the computer user we just changed to the uh login id which is come from the computer login computer login what i'm talking about is when you log in the computer like my laptop uh i have the account name this is t1 here this is my user when i log in on my computer if you work at the company on your workplace you will have the username or user id and a password to log in that we use that computer login to fill out on this login id for example like this i can my computer log in and this one is some k1 here i will put in here k1 and video admin user type id si2 we want to open the main form we can assign more command current database when the microsoft access display open we want to see the main display main form first and make it okay uh let's open this we got the error in here let's see why we get the area because this form is used with the login form which just need the id to put in there and open this form but however we don't have the login form now we just go to update the vb code under the onload it win this code is for you can see here tim from that login form that we use we're going to modify this code well what we need to do we can get the computer username or computer login name and say dim computer login name as string and then we assign to equal to nyron username now the user here we want to look up full name and the table and we wanna get now change the login name here login id equal to computer login name just copy this computer log in in a string we need to put a photo feed in the front and on the back right here the same thing over here i will just copy i'll try to open it now now because i'm logging in with the my computer username is t1 now you can say i will come to one from here if some personnel you know in the workplace that uh we haven't put their login id in the database and then they just try to open our file and let's see try it how we get an error here because invalid you use some new you know why because um you see when we use this criteria and come up with the zero or no matching with the data in the user table because that username is not in the database yet we haven't put in a user table we need to modify our code here when they put the eaves statement if it's no they look up then and then we can we want to say set the welcome to guess yes else and if at the end and also we want the admin page and the user info button is a disappear for that guess this name cdm you use info and that's a cmd admin page we just update the code here if it's guest and cmd admin page is visible to 4 and cmd using 4 visible equal to 4 now if the user in the user table or user already set up we come back over here if the admin we want the admin page enable else we can put visible equal to 4 this is kind of like a criteria we can just set up over here like criteria let's do it cut it two let aside the criteria to this log in right here let's add a login id equal to the computer log in name from the top here and now we will just put all the criteria here in the side of the loop up function it just make the code shorter and you don't have to tighten a long line again and again okay that looks less you know voting uh let's try it how the code work is inside the computer login id name from the computer login when you log in and the criteria is login id equal to that computing login name and e is that the computer login name is not in the database not in the user and will be take will come as a guess and not showing the admin page and not showing the user info button and if this in the system and then we come back say welcome and then the full name of that user and if that admin will be with admin page enable and if it's not and will be um disappear from that main menu let's try it database doesn't have my login id my login id is 101 now the main menu is a welcome guest and surely user list report button that i assign uh let's change to my computer log in here 181 now is open that welcome t1 and all this button display and show on the main menu that means you set up the user security level without a login form but using the computer login uh sometime you don't want there to log in every time or password uh just something simple you just use their computer log in and set up the security level in your database file this that house work let's add more command or set more user security type uh more than the admin and the user let's go at um we can add a manager here okay still got a smith as a manager okay and we delete this one and just log in with my computer name as a manager here adam smith before we do that we want to update some code under the main form when they log in we want to show you know different from the manager um on this one using admin we wanted everything you know edible add if is user type id equal to 3 manager else to three and we can put um admin it go to visible equal to 4 that means not show up or not display the admin page if just regular user maybe put um user info as visible not display on the regular user okay and we show everything use manager is it show user info and user risk report but not the admin we put number three here user type id equal to three miniature because conform the user type over here number three is a manager because there's an integer here and now let's try it okay i log in as items did because my computer log into t1 here they show adam smith and manager you know manager is show the user info and the user report and the admin page is not show up here because um items is manager is it's not an admin that we put in here is one disable and let's try with um jenny back here's user let log in t1 with the user you see a log in with john smith as a user now user is already see the user report john smith that's the way how we set up different level of the security this one we don't have to use the login form we just do the computer login to set the security type for the user on the screen right now i log in as a guest because of my computer login is not set up in the user table my computer login is um taiwan i haven't put in the data budget when you log in it open the main form and say welcome guest and show the report next step i don't want guests or the user that is not have the login id set up in database to open this database file you need to update the code under the guest section here this is a guest section if it's no computer login or no i log in id setup in the database now uh we don't want them to able to open the file we want them to get the message say you don't have a permission to open this database please contact your supervisor or your manager will be critical title is access deny i want them to get the message that they don't have a permission to open that database and after they click the ok button and then the define can be closed the program closing simday.quit i suggest that before you using this command you need to make a copy of your file i will make a copy of your my file first when i open that file my copy file and i got the message you don't have a permission to open this database please contact your manager and after i click ok and then the program close that i cannot open because you have to get the user login or computer login set up in the user table first this is how to set the user security with our login form and set different type of the user type to log in and to use in the database and thank you for watching
Info
Channel: T Golden Eye
Views: 2,191
Rating: 5 out of 5
Keywords: No Login form, Security, Computer Login
Id: Mgdn_YuOQF4
Channel Id: undefined
Length: 18min 38sec (1118 seconds)
Published: Mon Nov 30 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.