从目标页面我发现:
<legend><span class="labelOnMed">Plan name:</span> <span class="textOnMed">myCompanyName</span></legend>
有没有办法在特定的<span>
代码中检索或提取文字?
Loop %numberOfLink%
{
If (Links[A_Index-1].InnerText == cin) {
Links[A_Index-1].Click()
IELoad(wb)
planID := wb.document.getElementsByTagName("textOnMed")
MsgBox, %planID%
}
}
我也尝试过:
planID := wb.document.getElementsByTagName("textOnMed")
planString := planID.value
MsgBox, %planID%
答案 0 :(得分:1)
planID := wb.document.getElementsByClassname("textOnMed")[0].innerText