Disable Pg Up and Pg Down

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I need to disable the Page Up and Page Down buttons for a sub-form only.
Any assistantance will be appreciated.
 
1. Open the subform in design view.

2. Set its KeyPreview property to Yes.

3. Add code to the KeyDown event of the form.

4. If the KeyCode matches vbKeyUp or vbKeyDown, destroy the keystroke by
setting KeyCode to zero.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top