Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Disable PgUp and PgDown?

Status
Not open for further replies.

JennyPeters

Programmer
Oct 29, 2001
228
0
0
US
Is there a way to disable PgUp and PgDown right at the beginning of a DB program?

Thanks,

Jenny
 
On your open form, put a onKeyDown event. Trap for keycode 33 (page up) and 34 (page down). When these cases arrise, produce whatever result you desire, i.e. Me.Form.SetFocus


Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)

If KeyCode = 33 Or KeyCode = 34 then
Me.Form.SetFocus
End If

End Sub

Hope this helps.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top