Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

getting page source using IE 1

Status
Not open for further replies.

chriss87

Programmer
Jan 29, 2007
11
PL
Hello guys

I have a kind of an easy question - i'm not very much into writing scripts and thougth i could get some help.

I tried seeking the forum, but i guess i haven't found anything about it:

My script is used to navigate on websites, login in to accounts ect... but there is a little problem - mainly i do not know how to get the html source from the website my IE object is currently browsing...


Option Explicit

Dim oIE : Set oIE = CreateObject("InternetExplorer.Application")

oIE.navigate "[page adress]"


Do
WScript.Sleep 500
Loop Until oIE.ReadyState = 4

'other code...


First i'd like to store the html content to a string variable, and then save it to a text file using FSO [that i will manage]

Thanks in advance
chriss87

 
[tt]s=oIE.document.getElementsByTagName("html")(0).outerHTML[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top