Help with AllowBypassKey

  • Thread starter Thread starter gsnidow via AccessMonster.com
  • Start date Start date
G

gsnidow via AccessMonster.com

Greetings folks. I am having a hard time understanding where I go to access
the AccessObjectProperties collection. I am using Access 2003 .ADP with SQL
Server 2000. I have found some stuff that seems relavent in the VB editor,
and have looked it up in VB help. Specifically what I want to do is disable
the shift key, but I can not figure out how to do it based on the help
example. Can anyone point me toward where I actually type in the code?
Thank you.

Greg
 
Thanks Sylvain. I was able to find out 'what' to code, but I do not
understand how or where to type it. For example, if I want to enter code for
a form's event I go to design view and then open up the properties of the
form, click the three dots on the appropriate event, and the VB window opens
up. I do not understand where I am supposed to enter this code, nor where it
lives in the database. It seems there are properties governing the entire
database, just like there are for forms and controls, but I have no idea
where they "live". When I was searching for this topic I saw many references
to modules and macros. I kind of understand what a macro is, as long as it
is the same thing as in Excel, but I have no idea what a module is. If there
is not an easy explanation, could you maybe post some helpful links, that
make no assumptions with respect to one's Access acumen? Thank you.

Greg

Sylvain said:
For ADP, use:

CurrentProject.Properties.Add "AllowBypassKey", False
Greetings folks. I am having a hard time understanding where I go to
access
[quoted text clipped - 9 lines]
 
Easy: go to the VBA window and open the Immediate window: View | Immediate
Window. Enter the command there and then press [Enter]. You could also
create a form with two command buttons and enter the following code for
their OnClick events:

Private Sub cmdAllow_Click()
CurrentProject.Properties.Add "AllowBypassKey", True
End Sub

Private Sub cmdDisallow_Click()
CurrentProject.Properties.Add "AllowBypassKey", False
End Sub

--
Sylvain Lafontaine, ing.
MVP - Technologies Virtual-PC
E-mail: sylvain aei ca (fill the blanks, no spam please)


gsnidow via AccessMonster.com said:
Thanks Sylvain. I was able to find out 'what' to code, but I do not
understand how or where to type it. For example, if I want to enter code
for
a form's event I go to design view and then open up the properties of the
form, click the three dots on the appropriate event, and the VB window
opens
up. I do not understand where I am supposed to enter this code, nor where
it
lives in the database. It seems there are properties governing the entire
database, just like there are for forms and controls, but I have no idea
where they "live". When I was searching for this topic I saw many
references
to modules and macros. I kind of understand what a macro is, as long as
it
is the same thing as in Excel, but I have no idea what a module is. If
there
is not an easy explanation, could you maybe post some helpful links, that
make no assumptions with respect to one's Access acumen? Thank you.

Greg

Sylvain said:
For ADP, use:

CurrentProject.Properties.Add "AllowBypassKey", False
Greetings folks. I am having a hard time understanding where I go to
access
[quoted text clipped - 9 lines]
 
Thanks again Sylvain. That worked like a charm.

Sylvain said:
Easy: go to the VBA window and open the Immediate window: View | Immediate
Window. Enter the command there and then press [Enter]. You could also
create a form with two command buttons and enter the following code for
their OnClick events:

Private Sub cmdAllow_Click()
CurrentProject.Properties.Add "AllowBypassKey", True
End Sub

Private Sub cmdDisallow_Click()
CurrentProject.Properties.Add "AllowBypassKey", False
End Sub
Thanks Sylvain. I was able to find out 'what' to code, but I do not
understand how or where to type it. For example, if I want to enter code
[quoted text clipped - 26 lines]
 
Back
Top