0

working with c# win forms and i need label7 to show this text from HTML

<pre id="code" class="brush: text; plain-text">1</pre>

Just need it to show "1" in it from the html. The 1 does change numbers highest it got was 216 I believe. Just need to write it in label7.Text

I tried Regex.Match with it but i failed completely. It didn't work and I had no idea why. And people told me not to do it this way so idk. I heard about HTMLAgilityPack but how do i use it?

HTML Page https://www.dropbox.com/s/6te2udjz14tutpt/Verison.txt

Thanks in Advance...

Programerszz
  • 391
  • 1
  • 5
  • 15
  • Try IndexOf. For one-off string parsing tasks of limited complexity, just get the index of the plain-text"> and – MatthewMartin Dec 03 '14 at 03:36
  • 2
    It is unclear hat you tried and what problem you face with your code. So the only question left in you post is "how to use HtmlAgilityPack" - which is covered in linked duplicate. You'll need some XPath like `//pre[@id='code']`. – Alexei Levenkov Dec 03 '14 at 03:44

0 Answers0