So you need something like [^0-9\.-]
This just adds the dash to your existing match. You could get a lot better though, like this -?\d+(\.\d+)? -? matches an optional negative indiator, aka a dash \d+ is just numbers, same as 0-9, the only part of this regex that is required (\.\d+)? means match a decimal only when it has numbers after it, and this entire group is optional nathan strutz [www.dopefly.com] [hi.im/nathanstrutz] [about.me/nathanstrutz] On Fri, Dec 14, 2012 at 7:59 AM, Paul Giesenhagen <[email protected]>wrote: > > Heya, > > I know that some will know this quickly ... but I have ReplaceNoCase(str, > "[^0-9\.]","","ALL") > > And this takes -5 to 5 ... which is not what I want - I want to include > negative numbers what do I add to this regular expression to keep the > decimals (if there) and keep the negative if there? > > So > 5.24 is fine > -5.24 is fine > 5 is fine > -5 if fine > > $5.24 (replace the $) > $5,244.22 (replace the $ and the ,) > > Basically I need positive and negative integers to go into a float column. > > Thanks > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:353458 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

