From: "Michael W. Ryder" <_mwryder@...> Date: 2008-05-09T04:00:33+09:00 Subject: Re: to check for numericality Farrel Lifson wrote: > @val = someValue if ( Integer( someValue) rescue Float( someValue ) > rescue false) > How would you fix this so it would work for valid numbers such as "1,234.56"? I realize that the OP uses comma separators, but Excel would import the above number as "1,234.56" to a .csv file. > 2008/5/8 Sijo Kg : >> Hi >> I have >> @val=SomeValue #for example 00,02,aa >> How can I check @val contains only numeriacal(including zero) >> values..I have to avoid aa above (for example ) >> >> Sijo >> -- >> Posted via http://www.ruby-forum.com/. >> >> >