Matchtext
Dar Scott
dsc at swcp.com
Thu Jul 31 12:49:01 EDT 2003
On Thursday, July 31, 2003, at 10:58 AM, Alex Rice wrote:
> Here is one that handles different lengths for the digits, but doesn't
> check the ranges of the day and month numbers. But that could be done
> in transcript.
>
> put matchText(tLine, "(\d{1,2})/(\d{1,2})/(\d{2,4})", tDay, tMo, tYr)
I like this better. The other only did partial checking anyway, so if
date checking is needed, Transcript is a good way to go. The other did
have an advantage in that it would be less likely pick up something in
a long text that looked like a date but was not.
Dar Scott
************************************************************************
****
Dar Scott Consulting http://www.swcp.com/dsc/ Programming
Services
************************************************************************
****
More information about the use-livecode
mailing list