Try the UDF below :
Function GetLastDigits(byMixedString As String) As Variant
Dim Entries As String
Dim RegEx As Object, Matches As Object, Match As Object
Entries = byMixedString
Set RegEx = CreateObject("vbscript.regexp")
With RegEx
.MultiLine = False
.Global = True
.IgnoreCase = True
.Pattern = "(\d+)" ' Match any set of digits
End With
Set Matches = RegEx.Execute(Entries)
If VBA.Left(Matches(Matches.Count - 1), 1) = 0 Then
GetLastDigits = VBA.Right(Matches(Matches.Count - 1), Len(Matches(Matches.Count - 1)) - 1)
Else
GetLastDigits = Matches(Matches.Count - 1)
End If
End Function
Worksheet results running this UDF (you need to enter the Mixed String inside the Formula brackets bar):
