D
Dirk.Reimers
Hi all,
sorry for my dumb question:
I use the following code:
Dim request As WebRequest = HttpWebRequest.Create("http://" &
ip & _
/TVBrowserTimerEvent?command=add")
request.Credentials = New NetworkCredential("root", "toor")
Try
Dim response As HttpWebResponse =
CType(request.GetResponse(), HttpWebResponse)
Catch ex As Exception
MsgBox(ex.Message)
End Try
which is working fine if the server responds with Code 200 OK
But I'm not able to get any additional info if the request goes wrong.
The servers answer is (for example):
-----
HTTP/1.1 400 Function failed.
Connection: close
Content-Length: 46
Content-Type: text/html; charset=utf-8
service name don't match.
----
But I'm only able to retrieve the 400 error code by accessing the ex
element. I do not know how to access the additional "service name
don't match." information.
Any hints?
Thanx
Dirk
sorry for my dumb question:
I use the following code:
Dim request As WebRequest = HttpWebRequest.Create("http://" &
ip & _
/TVBrowserTimerEvent?command=add")
request.Credentials = New NetworkCredential("root", "toor")
Try
Dim response As HttpWebResponse =
CType(request.GetResponse(), HttpWebResponse)
Catch ex As Exception
MsgBox(ex.Message)
End Try
which is working fine if the server responds with Code 200 OK
But I'm not able to get any additional info if the request goes wrong.
The servers answer is (for example):
-----
HTTP/1.1 400 Function failed.
Connection: close
Content-Length: 46
Content-Type: text/html; charset=utf-8
service name don't match.
----
But I'm only able to retrieve the 400 error code by accessing the ex
element. I do not know how to access the additional "service name
don't match." information.
Any hints?
Thanx
Dirk