ESP32 unable to extract string from string based on Regexp mask

Hi, Excuse me for my ignorance, but how do I get the output 'ABC3D97' into a variable?
This code is entirely new to me but it works great. Thanks