Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

chang way

Status
Not open for further replies.

wdu94

Programmer
Aug 15, 2001
61
US
Hi, All,

I have a database project that includ 4 different interfaces. Each interface need login access.

Can everyone tell me how can i create the security for each interface??

Thank you very much.
Jeannia
 
Hi Jeannia!

I copied this here just in case you didn't see it in your other post.

One good method would be to make a form which you open and hide using the autoexec macro. This form should have a textbox where you will store the department name when the user logs in. Then in the forms for each interface use this code in the open event:

If Forms!YourForm!YourTextBox = "Staff" Or etc. Then
Cancel = -1
End If

Alternatively

Select Case Forms!YourForm!YourTextBox
Case "Staff", "etc."
Cancel = -1
End Select

This code will not allow the departments in your condition statement to open the form. Of course, you could be even more specific by allowing some to open the interface as read only or to lock certain textboxes. It can give you a lot of leeway.

hth
Jeff Bridgham
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top