[thelist] calling all regex studs
Rory.Plaire@wahchang.com
Rory.Plaire at wahchang.com
Wed Aug 22 19:19:18 2001
| obviously i need to strip the ", " (comma and trailing space).
Jeff,
Give this a try:
REReplaceNoCase(mask, ',?[ ]*[y*]', '','ALL')
Generally, what you are doing is matching the optional (0 or 1) comma and
optional (0 to many) spaces before the "yyyy". For the second comma, the one
before the year that you _want_ in there, would DataFormat put it back in
for you? Seems like it would... or you could append it to the string
concatenation like so:
date_pair = DateFormat(startdate, REReplaceNoCase(mask, '[y*]', '', 'ALL'))
& ' - ' & DateFormat(enddate, REReplaceNoCase(mask, '[y*]', '', 'ALL')) & ",
" & DateFormat(enddate, "yyyy")
Keep an eye on the wrapsody above...
<rory disposition="jazzed" alt="8~"/>