?
Solved

Unable to set the AllowShiftBypass in Microsoft Access

Posted on 2013-11-14
11
Medium Priority
?
369 Views
Last Modified: 2013-11-21
I am not able to access the macros in Microsoft Access to be able to set the AllowShiftBypass property. The Shift key does not work and I am not able to view the full menu items. So, I am not able to also access the design view. How do I set the AllowShiftBypass property in Microsoft Access 2010?

Thanks,

Shanthi
0
Comment
Question by:shanthi_joseph
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 4
11 Comments
 
LVL 75
ID: 39650420
The link below contains an MDB which allows you to 'set' and 'reset' the Shift Key Bypass from a REMOTE mdb.  
It's very cool. Scroll down the page to 'By Pass Shift Key Code'
And it works in A2010 also.
http://www.kallal.ca/msaccess/msaccess.html
0
 
LVL 85
ID: 39650922
This function will do it:
Function SetBypass(PathToDB As String)

    Dim dbs    As dao.Database
    Dim prop   As dao.Property
    Dim bFound As Boolean

    On Error GoTo SetBypass_Error

    Set dbs = dao.OpenDatabase(PathToDB)

    For Each prop In dbs.Properties
        If prop.Name = "AllowBypassKey" Then
            bFound = True
            prop = True
        End If
    Next prop

    If Not bFound Then
        '/ property was not found, so add it
        Set prop = dbs.CreateProperty("AllowBypassKey", dbBoolean, True)
        dbs.Properties.Append prop
    End If

SetBypass_Exit:
    On Error Resume Next
    dbs.Close
    Set dbs = Nothing
    Set prop = Nothing
    Exit Function

SetBypass_Error:
    Select Case Err.Number
            'Case 0
            'Case 1
        Case Else
            MsgBox "Error " & Err.Number & ": " & Err.Description & vbCrLf & vbCrLf _
                   & "Occured in Module1:SetBypass", vbOKOnly + vbExclamation, "Error"
            Resume SetBypass_Exit
    End Select
End Function

Open in new window

Add that to a Standard Module, then call it like this:

SetBypass("Full path to your database")

You'd need to do this from another database, not the one where you want to reset the Bypass key.

Also, if you're working with a compiled file (.accde or .mde) then you won't be able to go to design view at all.
0
 
LVL 75
ID: 39651881
Just noting of course that is exactly what Albert's db does - and it's already to go :-)
0
Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

 

Author Comment

by:shanthi_joseph
ID: 39659273
I am still not able to access the code and design. I still obtain the Login form when I open the database by clicking on the Shift key at the same time and I am not able to see the full set of menus. I set the AllowShiftBypass property of the database by calling the SetBypass method from another database.

Thanks
0
 
LVL 75
ID: 39659917
Did you use the mdb I posted ?
0
 

Author Comment

by:shanthi_joseph
ID: 39664453
I copied the SetBypass standard module into another database and ran the module with the parameter containing the full path of the database that needs the AllowShiftBypass property to be set . After running the standard module, I opened the database by clicking the Shift key at the same time. The database opened displaying the login form without showing the full set of menu items.  What else needs to be performed to be able to open the database such that it displays the full set of menu items.

Thanks,

Shanthi
0
 
LVL 75
ID: 39664572
But did you try using the MDB I posted ... and point to the target db?
0
 

Author Comment

by:shanthi_joseph
ID: 39664771
I used the database that was posted on the Web page. I obtained the message, Enable set, result = -1, when I try to enable the pass key. I am not able to see the full set of menu items when I open the database by clicking on the Shift key at the same time.  Do you know what may cause the result code of -1?

Thanks,
Shanthi
0
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform) earned 2000 total points
ID: 39665093
Not sure what is going on.
Be *sure* to hold the Shift down before you Open ... and keep shift key down until db is fully loaded.

?
0
 

Author Comment

by:shanthi_joseph
ID: 39667319
Thats great. I needed to hold the shift key down until db is fully loaded. Thanks so much.
0
 
LVL 75
ID: 39667363
Excellent.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question