Function
GetValueFromWeb()
Dim
oIE
As
Object
, sUrl
As
String
, oNode
As
Object
Set
oIE = CreateObject(
"InternetExplorer.application"
)
oIE.Navigate sUrl
oIE.Visible =
False
While
Not
oIE.readyState = 4: DoEvents: Wend
Set
oNode = oIE.Document.getElementById(
"wb-cont"
)
If
Not
oNode
Is
Nothing
Then
GetValueFromWeb = oNode.all.tags(
"span"
)(0).outerText
Rem GetValueFromWeb=oNode.outertext
End
If
Rem GetValueFromWeb = oIE.Document.getElementById(
"MyID"
).outertext
oIE.Quit
Set
oIE =
Nothing
Set
oNode =
Nothing
End
Function