MS Access Version 2412 Build - VBA to override default form record scrolling behavior no longer works

Anonymous
2025-01-13T22:49:52+00:00

I have several continuous and single forms and use the following code to override the default record scrolling behavior. With the January 7 MS Office update, nad update to Access Version 2412, the following mouse wheel event code no longer works.

What changed in Version 2412?

I've also tried changing it to DoCmd.GoToRecord , , acPrevious etc. but the default record scrolling behavior in forms is what persists.

On Error GoTo Err_Handler

    'Purpose:   Make the MouseWheel scroll in Form View in Access 2007 and later.

    '           This code lets Access 2007 behave like older versions.

    'Return:    1 if moved forward a record, -1 if moved back a record, 0 if not moved.

    'Author:    Allen Browne, February 2007.

    'Usage:     In the MouseWheel event procedure of the form:

    '               Call DoMouseWheel(Me, Count)

    Dim strMsg As String

    'Run this only in Access 2007 and later, and only in Form view.

    If (Val(SysCmd(acSysCmdAccessVer)) >= 12#) And (frm.CurrentView = 1) And (lngCount <> 0&) Then

        'Save any edits before moving record.

        RunCommand acCmdSaveRecord

        'Move back a record if Count is negative, otherwise forward.

        RunCommand IIf(lngCount < 0&, acCmdRecordsGoToPrevious, acCmdRecordsGoToNext)

        DoMouseWheel = Sgn(lngCount)

'        If lngCount < 0& Then

'            DoCmd.GoToRecord , , acPrevious

'        Else

'            DoCmd.GoToRecord , , acNext

'        End If

    End If

Exit_Handler:

    Exit Function

Err_Handler:

    Select Case Err.Number

    Case 2046&                 'Can't move before first, after last, etc.

        Beep

    Case 3314&, 2101&, 2115&   'Can't save the current record.

        strMsg = "Cannot scroll to another record, as this one can't be saved."

        MsgBox strMsg, vbInformation, "Cannot scroll"

    Case Else

        strMsg = "Error " & Err.Number & ": " & Err.Description

        MsgBox strMsg, vbInformation, "Cannot scroll"

    End Select

    Resume Exit_Handler

End Function
Microsoft 365 and Office | Access | For business | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes
Answer accepted by question author
  1. Anonymous
    2025-01-15T01:44:59+00:00

    The Access team have been able to replicate the Count bug with the repro database I sent them and have confirmed that it will be fixed.

    Although not mentioned in this thread, I cannot see how the Page argument would ever be true.

    3 people found this answer helpful.
    0 comments No comments
Answer accepted by question author
  1. Anonymous
    2025-01-22T23:49:31+00:00

    News from the Access team

    The mouse wheel issue will be fixed in version 2501, which will be available next week (W/C 27 Jan)

    My related article on the Access Forever blog site will be updated again when the release date and build number are known

    The Beta Channel should be fixed at around the same time

    1 person found this answer helpful.
    0 comments No comments

11 additional answers

Sort by: Most helpful
  1. Anonymous
    2025-01-28T15:34:27+00:00

    Hi,

    > Microsoft® Access® for Microsoft 365 MSO (Version 2501 Build 16.0.18429.20044) 64-bit

    This looks like a beta channel build which is not supposed to include a fix yet.

    To be sure about your version and build you should NOT state the info from the About Access dialog but the version, build number and channel name from the File - Account page.

    Servus
    Karl
    ****************
    Access Forever News DevCon
    Access-Entwickler-Konferenz AEK

    0 comments No comments
  2. Anonymous
    2025-01-28T15:38:50+00:00

    Hi

    That's strange.

    The MS website doesn't list a new Current Channel release yet and I cannot find that build listed on their website: Update history for Microsoft 365 Apps (listed by date) - Office release notes | Microsoft Learn

    Please can you provide the version / build / release channel info next to the About Access button. The info seen when you click the button is often different (and not the Office build)

    Another user at AccessForms.net does have the fix with Version 2501 Build 18429.20114 which is Current Channel (Preview). I'm on the Beta Channel Version 2502 Build 18516.20000 and don't yet have the fix

    0 comments No comments
  3. Anonymous
    2025-01-28T18:52:59+00:00

    Thanks. I'm at build 18429.20088

    I'll probably get 20114 soon enough. Thanks again!

    0 comments No comments