I have some code which may help you to sort out your mouse wheel problem in Access 2007. Just insert the following code to the form’s On Mouse Wheel event procedure:
Code:
Private Sub Form_MouseWheel(ByVal Page As Boolean, ByVal Count As Long)
If Not Me.D Then
If (Count < 0) And (Me.CR > 1) Then
DoCmd.GoToRecord , , acPrevious
ElseIf (Count > 0) And (Me.CR <= Me.Recordset.RecordCount) Then
DoCmd.GoToRecord , , acNext
End If
Else
MsgBox "The record has distorted. Save the present record earlier than moving to an additional record."
End If
End Sub
You will have to regulate the code over if your form does not permit additions or is read only. It presumes you can scroll to a new record. You would only require regulating the state in the Else If statement. If the record has been restructured, you will likely wish to force the user to save the record sooner than scrolling. That was one of the major causes for this alters. Users would scroll the mouse wheel and automatically and without warning save their changes to their record.
Bookmarks