0
I am reading an html file and need to get the value of value
of select
user selected, how to do ?
HtmlAgilityPack.HtmlDocument doc = new HtmlAgilityPack.HtmlDocument();
var select = doc.DocumentNode.SelectNodes("//table//tr//td//select[@class='CC_CxComboBox']");
foreach (var item in select)
{
var _value = item... //"como pegar o valor do atributo value do select"
}
This is the HTML
<table>
<tr>
<td Class='Tit08'>CNPJ: 09876543210000 - JOÃO DA SILVA </td>
<td Class='Tit08'>Grupo:
<select id='grupo' class='CC_CxComboBox'>
<option value=''>Selecione</option>
<option value=02161 selected>SÃO PAULO</option>
</select>
</td>
</tr>
</table>
This is exactly what html looks like?
– Leandro Angelo