<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://jaysonknight.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx</link><description>I came across this little dandy whilst browsing a very popular asp.net community site (code like this makes me want to beat whoever wrote it to death with a wet noodle); the question was “how do I test a string to see if it’s numeric”…one of the answers</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP2 (Debug Build: 40407.4157)</generator><item><title>re: Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx#1750</link><pubDate>Fri, 12 Aug 2005 08:54:28 GMT</pubDate><guid isPermaLink="false">68946f8a-ff84-48ba-8722-56d2a9e13499:1750</guid><dc:creator>mousse</dc:creator><description>ok, i made these without thinking too hard:  for ints try ^([-+]?\d+)$  for floats, try ^([-+]?\d+\.?\d*)$  presuming +/- negatives rather than paren negatives.  www.regexlib.com == da bomb&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://jaysonknight.com/aggbug.aspx?PostID=1750" width="1" height="1"&gt;</description></item><item><title>re: Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx#1748</link><pubDate>Fri, 12 Aug 2005 06:30:07 GMT</pubDate><guid isPermaLink="false">68946f8a-ff84-48ba-8722-56d2a9e13499:1748</guid><dc:creator>Jayson Knight</dc:creator><description>Someone provide the regex and I'll be happy to run some performance tests...I'm gunning for the char[] solution to be the fastest, but I'd love to be proven wrong!&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://jaysonknight.com/aggbug.aspx?PostID=1748" width="1" height="1"&gt;</description></item><item><title>re: Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx#1747</link><pubDate>Fri, 12 Aug 2005 03:01:25 GMT</pubDate><guid isPermaLink="false">68946f8a-ff84-48ba-8722-56d2a9e13499:1747</guid><dc:creator>mousse</dc:creator><description>er, an iterated char-array solution? sounds like a PITA for just assessing if a string's numeric.. what about regular expressions? i don't honestly know how weighty their overhead..&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://jaysonknight.com/aggbug.aspx?PostID=1747" width="1" height="1"&gt;</description></item><item><title>re: Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx#1745</link><pubDate>Thu, 11 Aug 2005 17:47:39 GMT</pubDate><guid isPermaLink="false">68946f8a-ff84-48ba-8722-56d2a9e13499:1745</guid><dc:creator>Keyvan Nayyeri</dc:creator><description>You added a false &amp;quot;q&amp;quot; to ASP.NET forums link! ;) And another issue about CS: Your commenting system does not remember me!!&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://jaysonknight.com/aggbug.aspx?PostID=1745" width="1" height="1"&gt;</description></item><item><title>re: Test if a String is Numeric</title><link>http://jaysonknight.com/blog/archive/2005/08/10/Test-if-a-String-is-Numeric.aspx#1741</link><pubDate>Thu, 11 Aug 2005 08:58:23 GMT</pubDate><guid isPermaLink="false">68946f8a-ff84-48ba-8722-56d2a9e13499:1741</guid><dc:creator>Haacked</dc:creator><description>Since your trackbacks are down, I thought I'd do a manual trackback here.  &lt;a rel="nofollow" target="_new" href="http://haacked.com/archive/2005/08/10/9293.aspx"&gt;http://haacked.com/archive/2005/08/10/9293.aspx&lt;/a&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://jaysonknight.com/aggbug.aspx?PostID=1741" width="1" height="1"&gt;</description></item></channel></rss>