How can I get the list_price in the HTML below into a string variable using the browser? I tried the code below but response.Result is null.
- Code: Select all
<tr><td colspan="3" nowrap="nowrap" class="product_option">Retail Price: <span id="list_price" class="list_price">$20.95</span></td></tr>
- Code: Select all
string script = string.Format("document.getElementById('list_price').value;");
chromeBrowser.ExecuteScriptAsync(script).ContinueWith(x =>
{
var response = x.Result;
if (response.Success && response.Result != null)
{
var listPrice = response.Result;
}
});