[VB] Display InnerText from Website in TextBox

03/25/2015 15:05 MARCI1111#1
Hello guys,
i want to display the text from a website in a TextBox. I use the webbrowser from Visual Basic Studio, so it should be possible. The Problem is, that i just want to display a specific part of text.

Here is the example from the website:
PHP Code:
<!doctype HTML>
</
html>
<
headMy Website </head>

<
body>
<
span style="color:blue">5</span>
<
span style="color:blue">5</span>
<
span style="color:green"><b>10</b></span>
</
body>

</
html
I just want to display the "10" from the 3rd span element. So i need <span style="color:green"><b>10</b></span> but i just want to display the number 10 in my textbox...

Thanks & Greetings,
MARCI1111
03/25/2015 22:25 Darkangel44#2
Hey Marc,

try something like HtmlDocument: [Only registered and activated users can see links. Click Here To Register...]

With that, you only need to know how you wanna select the right span element. You can find it by index (in that case it's the third one), by attribute (e.g. "color:green") or by content (e.g. "<b>10</b>").

If you have further questions or need a example code (try it yourself first and google a bit) - just ask.


Grettings,
Darkangel44