18 lines
336 B
VB.net
18 lines
336 B
VB.net
Option Explicit
|
|
|
|
Const sURL="https://sourceforge.net/"
|
|
|
|
Dim oHTTP
|
|
Set oHTTP = CreateObject("Microsoft.XmlHTTP")
|
|
|
|
On Error Resume Next
|
|
oHTTP.Open "GET", sURL, False
|
|
oHTTP.Send ""
|
|
If Err.Number = 0 Then
|
|
WScript.Echo oHTTP.responseText
|
|
Else
|
|
Wscript.Echo "error " & Err.Number & ": " & Err.Description
|
|
End If
|
|
|
|
Set oHTTP = Nothing
|