Any regex gurus out there know if there is a pattern to test the number of 
commas in a string? I was thinking something along these lines but this doesn't 
quite do it. I'm lousy at regex ;) 

<cfset list = "1,2,3,,5,,,,9,10"> 
<cfset matched = reFindNoCase("([^,]*?,[^,]*?){9,9}", list)>
<cfif matched gt 0>
   found exactly 9 commas
<cfelse>
   no match
</cfif>

Janet 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion is delivering applications solutions at at top companies 
around the world in government.  Find out how and where now
http://www.adobe.com/cfusion/showcase/index.cfm?event=finder&productID=1522&loc=en_us

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:293775
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to