Multiple users and employee ID's

rustyg

life enthusiast
Local time
Today, 06:31
Joined
Jun 1, 2005
Messages
22
I am nearly ready to release my ACCESS 2000 database to 150 employees in our office (client/server network). However I have two problems, I have looked through countless posts and cant find exacly what Im looking for.

ACCESS automatically defaults to each individuals network ID when it is opened, so I have set that as UserName for each user, I have created a UserDetails table with this netowrk ID as a primary key, linking that as a foreign key to various OrderDetails tables. My question is how on earth can I get ACCESS to automatically enter this UserName onto each order a particular user makes? to be able to run queries for specific users etc? I dont want the user to be able to manually type in this because it can compromise the integrity of our data.

secondly, what is the best way to set up the FE, BE situation on our network? I tried the wizard and it gets a bit technical

Cheers for the help and congrats to a very helpful site,
Russ :)
 
Set up FE-BE on a Network

>>>> what is the best way to set up the FE, BE situation on our network? <<<<

As you have mentioned, there is a wizard for this. However I do prefer to do this myself and not use the wizard. Before you do anything, make sure you have some backups!

Make two copies of your database, name one MyDataBaseFE.mdb and the other MyDataBaseBE.mdb. in the front end one (MyDataBaseFE.mdb) delete all the tables, and in the backend one (MyDataBaseBE.mdb) delete everything but the tables. Put the backend one on your server, put it somewhere on the server where it will never be moved. Usually a good idea to create your own folder called something like C: MainDatabase.

Load up the front end DB (MyDataBaseFE.mdb) on any front end PC that has access to that particular server. Activate the linked table manager, point it at the database on the server, the backend DB (MyDataBaseBE.mdb) and establish the links.

Your frontend DB is now setup and it should work from any computer that has access to that particular server. Just copy it and give it to anybody that needs to use it. It will automatically link to the data on the backend server.
 
Look up the CurrentUser function in help. That will give you the user name. You can use that to populate the user name with each order.
 
rustyg said:
I am nearly ready to release my ACCESS 2000 database to 150 employees in our office (client/server network).

Are you sure Access is the wise choice for this? Although Microsoft say that an Access database can have approx. 255 concurrent users it usually begins to crawl at about 20 users.
 
Rusty, how many users will attempt to use this DB at the same time? If the answer is more than about 15-20 AND you are using Wide-Area-Networking technology, you might be disappointed with response.
 
There will be only up to 20 users at any one time so that shouldnt be a problem. I am still, however having trouble recognising the particular user's name and automatically updating records with this user name as something to identify they actually made that order. I searched teh help as suggested but still come up with nothing, any thoughts anyone?
 
You need to use a custom function and call it from the default value property for the control on the form.

If the DB is secure then you can get the login name with
Function GetUser()
GetUser = CurrentUser
End Function

or else you can get the user name from windows with

Function GetUser()
GetUser = Mid(Environ(28), 10)
End Function

HTH

Peter
 
Thanks Mate,

Forgive my ignorance here, Im only new at this. I have made a module with the GetUser = CurrentUser etc etc that you said to do.

Then do I make a defalt value in the UserNumber field of my table as
=GetUser()

Well thats what I tried to do and it didnt work, if possible could you please dumb it down a couple more notches?

Thanks again,

Russ
 
You are making it harder than it should be to get the users network name. The Environ() function will simply do it for you.

For a quick test...
Code:
MsgBox "Users network name = " & Environ("UserName")
MsgBox "Users computer name = " & Environ("ComputerName")
Check this link out for another twist... get real user name
 
If you want the db login name then you will have to do it from the form with my function.
ghudson's Environ("UserName") can be used as a default value in the table to get the PC login name.

Peter
 
Access 2003 will not let you use many functions [built-in or custom] like =Environ("UserName") as the default value for a field in a table. Access 97 would.

Also, some of the Environ numeric values are different for each version of Windows. Use the strings like "UserName" to ensure consistant results.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom