DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/index.php)
-   VB.NET (http://www.daniweb.com/forums/forum58.html)
-   -   VB.Net HTML document read (http://www.daniweb.com/forums/thread156884.html)

jahanna Nov 12th, 2008 2:26 pm
VB.Net HTML document read
 
Hey guys, i need to read form(s) on VB.Net from the simple html based web sites, like on VB6 webbrowser object;
 WebBrowser.Document.All("form").All("field")
But i shouldn't to use a WebBrowser object. How can i do this on VB.net?

simulanics Nov 19th, 2008 3:13 pm
Re: VB.Net HTML document read
 
Dim i As Integer = 0

If WebBrowser1.Document IsNot Nothing Then

Dim str As String = String.Empty

For Each form As HtmlElement In WebBrowser1.Document.Forms

i = i + 1

str = i.ToString + " " + str + form.Name + vbCrLf

str = str + form.GetType.ToString + vbCrLf

str = str + form.InnerText.ToString + vbCrLf

str = str + form.OuterText.ToString + vbCrLf

Next

MessageBox.Show(str)


-------------------------------------
Hope this helps :-) Ask me anything you need to know. Any proggin lang too :-) admin@simulanics.com

jahanna Nov 20th, 2008 11:14 am
Re: VB.Net HTML document read
 
Thanks for reply the topic simulanics but my problem is little different. I can not be use the Webbrowser control on this program. How can i do this with another way? Thats all i need. If you know the another way to do this i realy greatful.

sierrainfo Nov 21st, 2008 1:40 am
Re: VB.Net HTML document read
 
hi
see the following links. I hope it will help u.

http://www.codeproject.com/KB/books/0764549146_8.aspx

http://www.codeproject.com/KB/recipe...5_Browser.aspx

jahanna Nov 21st, 2008 4:38 am
Re: VB.Net HTML document read
 
It's still webbrowser component :D is it different way to do this ? Or its can be just with webbrowser anyway thanks 4 the helps.

simulanics Jun 19th, 2009 2:10 am
Re: VB.Net HTML document read
 
Use the WebRequest Class built into the .Net Framework..check out my newest software title Simulanics Mobsters Bot...just google it..I'm sure you'll get a hit :-D..but using a similar class built for vb6 my proggies do the same thing...but stick with the example on the following site...it should help u :-)

http://www.vbdotnetheaven.com/Upload...uestClass.aspx


All times are GMT -4. The time now is 3:20 am.

Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC