VB.NET
string s= oElement2.InnerText;
string nonNumericValue = string.Concat(s.Where(a => !Char.IsDigit(a)));
double dblPrice = Convert.ToDouble(s);I am parsing a webpage and the result "1,500\r\nIn Stock" crashes my application. I am trying to exclude all the nonnumeric characters. Is this Lambda Expression incorrect ? thank you in Advance.

Nishant MittalRank #692 · 3.5K reputationPosted Nov 19, 2015, 6:44 AM EST
Emphatic4 reputationPosted Nov 19, 2015, 7:09 AM EST
Nishant MittalRank #692 · 3.5K reputationPosted Nov 19, 2015, 6:25 PM EST