Bug Alert: Assertion Failed on RegExp Calls in Access 2508

Two separate sightings of the same error on two entirely different machines within hours of each other is likely no coincidence. I hope this doesn't ruin my long weekend...

Bug Alert: Assertion Failed on RegExp Calls in Access 2508

Quick post to get this out in the wild and see if anyone else is having similar issues.

I started getting the following error just a couple of hours ago (about 1 PM EDT on 29 Aug 2025):

The error was first reported by a customer who was getting it in one of our deployed applications. This is calling code that has not been touched in years.

Another computer with the same application at the same client did not receive the error. Key difference between the two computers? Their Access versions.

  • BAD: Access version 2508: this computer got the error shown above
  • GOOD: Access version 2507: no error message; RE.Replace() works as normal

I checked the Office update history on the computer, but that just takes you to the following website: Release notes for Current Channel.

Release notes for Current Channel releases - Office release notes
Provides IT Pros with release notes for Monthly Channel releases for Microsoft 365 Apps.

Here's the text of the website at the time of publication:

I told my customer to wait until after the long weekend to give Microsoft a chance to fix the problem, as his was the only complaint I had received.

And then a few hours later, I fired up a different Access application on a different machine (my dev machine) and got the same unhappy error message on the same lines of code:

Microsoft Visual C++ Runtime Library
Assertion failed!

Program: ...
File: g:\vba\src\65_VC8\VBA\rt\rtre.cxx
Line: 946

Expression: replaceVar.vt == VT_BSTR

For information on how your program can cause an assertion
failure, see the Visual C++ documentation on asserts

(Press Retry to debug the application - JIT must be enabled)

I worry that this may be related to Microsoft's plans to kill off VBScript, which is the library that provides RegEx support in VBA:

Microsoft Announces the Death of VBScript
As seems to be their new modus operandi, Microsoft has quietly rolled a hand grenade into the VBA development world with very little fanfare.

I should note that VBScript itself is working just fine on my computer (running Win 11). It has not even switched over to a Feature On Demand (yet). So maybe I'm just being paranoid.

My fear, if this doesn't get resolved quickly, is that I will need to reimplement all of my VBA regex functionality using some other alternative on a much shorter timeline than I anticipated. This is probably where I would start:

GitHub - sihlfall/vba-regex: A regular expression engine written entirely in VBA
A regular expression engine written entirely in VBA - sihlfall/vba-regex

Let's hope it doesn't come to that...at least not yet.

All original code samples by Mike Wolfe are licensed under CC BY 4.0