comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » stregex with multiple matches
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
stregex with multiple matches [message #88670] Thu, 29 May 2014 11:31 Go to previous message
PMan is currently offline  PMan
Messages: 61
Registered: January 2011
Member
Hello,

Can stregex match an expression multiple times? It seems not, but I get the feeling there ought to be a way to do so. For example:


IDL> time_regex = '([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])'


IDL> timeStr = '10:21:41"
IDL> print, stregex(timeStr, time_regex)
0

Ok, that is what expected


IDL> timeStr = '10:21:41 - 11:32:00"
IDL> print, stregex(timeStr, time_regex)
0

But in the second example, why aren't there two matches? can I change my regex in some why to get multiple matches?

Thanks
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: GDL workshop in France, 10-13 June 2014
Next Topic: Create an XML file in IDL

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 15:20:29 PDT 2025

Total time taken to generate the page: 0.00428 seconds