I have just managed to accomplish this very thing.
Paste the following code into a new module:
Function ChangeProperty(strPropName As String, varPropType As Variant,
varPropValue As Variant) As Integer
Dim dbs As Object, prp As Variant
Const conPropNotFoundError = 3270
Set dbs = CurrentDb
On Error GoTo Change_Err
dbs.Properties(strPropName) = varPropValue
ChangeProperty = True
Change_Bye:
Exit Function
Change_Err:
If Err = conPropNotFoundError Then ' Property not found.
Set prp = dbs.CreateProperty(strPropName, _
varPropType, varPropValue)
dbs.Properties.Append prp
Resume Next
Else
' Unknown error.
ChangeProperty = False
Resume Change_Bye
End If
End Function
You then need to create two command buttons, one to disable the shift key,
the other to enable it.
Disable:
Private Sub diable_Click()
Const DB_Boolean As Long = 1
ChangeProperty "AllowBypassKey", DB_Boolean, False
End Sub
Enable:
Private Sub enable_Click()
Const DB_Boolean As Long = 1
ChangeProperty "AllowBypassKey", DB_Boolean, True
End Sub
Hope this helps,
Mark
"Susan Bricker" <sb****@att.net> wrote in message
news:41**********************@news.newsgroups.ws.. .
I know that I saw some information concerning the <shift>+<enter>
combination use to bypass launching an Access mdb application and enter
the Access design workspace. Would someone please direct me to some
information on how to disable this function (and how to re-enable it)?
I believe that I saw some article that showed how to incorporate this
into a command button. That would work for me as I have three different
sign-on authorities for my application and I would only display the
command button for the 'admin' authority. Thanks, in advance, for your
help.
Sue
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!