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
Solved

Unable to set the AllowShiftBypass in Microsoft Access

Posted on 2013-11-14
11
364 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
  • 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 84
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
The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

 

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 500 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

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

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

This article is a continuation or rather an extension from Cascading Combos (http://www.experts-exchange.com/A_5949.html) and builds on examples developed in detail there. It should be understandable alone, but I recommend reading the previous artic…
A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.

856 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