Well, you should be able to do this using REFind.

For example, REFind("[0-9]*", <myString> , 1, true)>

Look at the Help for REFind for handling the returned position and length of
the found item(s).  You'll have to figure out how to handle multiple numbers
in your string.


-----Original Message-----
From: Ethan Rosch [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 1:26 PM
To: CF-Talk
Subject: pull numbers from a string...


Hi all..

is there a funcion that wil strip everything out of a string except numbers?

ie.  The width of the box is 54"

and I want to set

<CFSET Width = 54>

something like

<CFSET Width = NumberStrip("The Width of the box is 54")>

#width# = 54

thanks in advance,

ethan
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to