Using regular expressions to extract a value from a field

I am trying to take an inbound field that may or may not contain a part number, and may or may not contain additional text (it can essentially contain anything, so I would search the entire field). I want to search the field for a pattern, not a specific part number (so I am looking for #AA#A where # is a number, and A is alpah-numeric). If the pattern is found, I will extract it and map it to the appropriate field. But I am having difficulty extracting it.

I am using the indexOf service. The inString field is the one I want to search for a part number pattern. The substring is a regular expression. I currently tried a test from the wM users guide {doc.p[/web.ethods/].text}, that came back null.

I am getting a -1 (not finding the string) for this. Any thoughts on how I can extract this data correctly?

I am getting nothing…
/\d\w\d\d\d/ and
\d\w\d\d\d

That should be the correct expressions for number only (\d) and alphanumeric (\w). I am not getting any value returned???