Click here to Skip to main content
15,889,838 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have just used htmlagilitypack to extract all link as htmlnode from an html
document, but i need this returned from my function as htmlelement
VB
Dim Tags As HtmlNodeCollection = docNode.SelectNodes(strXpath)
  Dim ListResult As New List(Of HtmlElement)
  For Each Tag As HtmlNode In Tags
     ListResult.Add(Tag.Element)
 Next
Return Nothing


How can i do this?
Posted

1 solution

If your code is correct and compiles, what you failed to mention, why not just do Return ListResult; instead of Return Nothing;

Just saying.

Regards,

Manfred
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900