I need to get numeric values from a web page into two variables.
A snippet from the page is below
<b>Downloads (current version):</b> 123 <br />
<b>Downloads (total):</b> 253</td>
<br />
The "Downloads (current version):" and "Downloads (total):" are unique strings in the page.
I need to get the "123" and "253" into variables
Edit: Thanks to har07 I ended up with
var downloadscurrentversion = htmlDoc.DocumentNode.SelectSingleNode(@"//b[.='Downloads (current version):']/following-sibling::text()[1]");
var downloadsallversions = htmlDoc.DocumentNode.SelectSingleNode(@"//b[.='Downloads (total):']/following-sibling::text()[1]");
Console.WriteLine("Total: " + downloadsallversions.InnerText.Trim());
Console.WriteLine("Current: " + downloadscurrentversion.InnerText.Trim());