473,378 Members | 1,139 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

relinquish control after password

26
Hi all,
The problem is that when someone logs into my database they have to enter a user name and password. Then they are directed to my Z_Menu_Main form and they can work from there. And on startup I have allowed only the display statues bar to be shown. The problem that I have is that a new database needs the same set up but after the password is entered to relinquish control of the database so that all the functionality is there, as if the startup was never limited. The problem is that do not know how to do this. Any help would be much appreciated. I have included my code if that will help



Private Sub Command14_Click()
Dim usrArray As Variant
Dim pwArray As Variant

usrArray = Array("*******", "*******", _
"*******", "*******", "*******", _
"*******")

pwArray = Array("*******", "*******", _
"*******", "*******", "*******", _
"*******")

For i = 0 To UBound(usrArray)
If ((Me![username] = usrArray(i)) And (Me![password] = pwArray(i))) Then
Me![passfail] = "Pass"
DoCmd.Close
DoCmd.OpenForm "Z_Menu_Main"
Exit Sub
End If
Next i

Me![passfail] = "Fail"
DoCmd.Close
DoCmd.OpenForm "Z_LogonFail"

End Sub
Jun 11 '08 #1
3 1276
ADezii
8,834 Expert 8TB
I've never used it, but I imagine that the easiest solution would be to programmatically set the Default Workgroup Information File, (not Secured), once the correct Password has been entered. This would be a 1 shot deal, and of course the WIF would have to exist and be in the correct Path, as in:
Expand|Select|Wrap|Line Numbers
  1. Application.SetDefaultWorkgroupFile path:="C:\Documents and _ Settings\Security\Application Data\Microsoft\Access\system.mdw"
Jun 11 '08 #2
BUmed
26
I do have it setup to have a password when you first login to access but after that I have another password and user name. The reason for the second password is to keep track of who is in the database. So there may not be a way to change the startup setting using vba?
Jun 11 '08 #3
ADezii
8,834 Expert 8TB
I do have it setup to have a password when you first login to access but after that I have another password and user name. The reason for the second password is to keep track of who is in the database. So there may not be a way to change the startup setting using vba?
You can programmatically change all of the StartUp Options with VBA Code. StartUp Properties are properties of a Database Object. A Database Object is a DAO Object supplied by the Microsoft Jet Database Engine, but StartUp properties are defined by Microsoft Access, so they aren't automatically recognized by the Jet Database Engine. If a StartUp Property hasn't been set previously, you must create it and add it to the Properties collection of the Database object. Here are the actual Property Names for their corresponding StartUp Options.
  1. AppTitle
  2. AppIcon
  3. StartupForm
  4. StartupShowDBWindow
  5. StartupShowStatusBar
  6. StartupMenuBar
  7. AllowFullMenus
  8. AllowShortcutMenus
  9. StartupShortcutMenuBar
  10. AllowBuiltInToolbars
  11. AllowToolbarChanges
  12. AllowSpecialKeys
Jun 11 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Chris Barrow | last post by:
Hi everyone, Does anyone know if there is a problem populating a system.web.ui.htmlcontrols.htmlinputtext control when the control's type is set to "password?" I am attempting to retreive a...
6
by: Andre Ranieri | last post by:
I'm trying to create a login page for customers to log into our corporate website, our presidents naturally wants the user and password fields to populate from a cookie so the customer doesn't have...
1
by: Hardy Wang | last post by:
Hi all, I have a login control, like below <asp:Login ID="loginPanel" runat="server" BorderPadding="0" PasswordRecoveryText="Click to retrieve your password" TitleText="Enter Your Username &...
1
by: EricRybarczyk | last post by:
I am starting a rewrite of an existing Classic ASP web site in ASP.NET 2.0. The existing ASP application has several types of users, each with a separate login process (separate login page,...
3
by: vtxr1300 | last post by:
I'm trying to create a login box control to use that simply exposes the username, password and remember me properties when the login button is clicked. I have the button click wired up and working...
5
by: Afshar | last post by:
Hi everybody there, I have a special Login page that wants users to enter 3 passwords rather than a single password. But can't do it with Login control. I tried following scenarios: 1. Put an...
0
by: =?Utf-8?B?am1obWFpbmU=?= | last post by:
I'm trying to create a process that allows me to limit the non-alphanumeric characters generated with the PasswordRecovery control. Specially I want to suppress some characters for security...
1
by: jqheller | last post by:
Folks I am losing my mind trying to work with the TemplatedWizardStep. I have created a multistep user registration form that collects plenty of user information including a password. At the end...
2
by: Ken Fine | last post by:
I want to add the security question and answer security feature to the ChangePassword control. I am aware that this functionality is built into the PasswordRecovery tool. I have implemented the...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.