我有这个结构:
<p class="info">Sample:
<strong>
<a href="http://PleaseGetMe.com"target="_blank">http://PleaseGetMe.com</a>
</strong>
</p>
我想要的是获得http://PleaseGetMe.com
以下是我的尝试:
var a = doc.SelectNodes("//*[@class='info']//a");
Console.WriteLine(a);
哪个不成功。
答案 0 :(得分:0)
这是我的实施
Set d = .Find(What:=a, After:=ActionCodeCell, LookIn:=xlValues, _
LookAt:= xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlPrevious, _
MatchCase:=False, SearchFormat:=False)
If d is Nothing Then
Set d = .Find(What:=b, After:=ActionCodeCell, LookIn:=xlValues, _
LookAt:= xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlPrevious, _
MatchCase:=False, SearchFormat:=False)
End If