I've been trying to do the following using VBs Regular Expression object but could not find an easy way to do it. Is there anyone who could provide some suggestions?
For example, I have a string "12<56>89", I would like to get the string inside the "<>" which should be "56" in this case. What I'm currently doing is I try to find the expression "<d+>" which will return <56>. Then I try to find the expression "d+" from the result of the first match which will return 56.
I don't like this way because it needs to call the function twice. I'm wondering if it's possible to get the string inside the "<>" using just one regular expression? Thank you!
Thanks,
Allen
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…