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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

center mouse scrolling records 1

Status
Not open for further replies.

ErnNJ

Programmer
May 2, 2002
21
US
Is there a way to stop the scroll button from scrolling through active records on a form? I have a form with fields bound to a table that I want to use for updating only one record at a time. I took off the navigation buttons and the scroll button still scrolls through the records.
 
You have to disable the keys that cause the scrolling. here is an example of the code to do this. Private Sub Extension_KeyDown(KeyCode As Integer, Shift As Integer)
Select Case KeyCode
' If user presses TAB, ENTER, PAGE UP, PAGE DOWN
Case 13, 9, 33, 34
' Disable the keystroke by setting it to 0
KeyCode = 0
Case Else
Debug.Print KeyCode, Shift
End Select
End Sub

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top