webrequest.create(URL)中的NUll引用异常

时间:2013-03-11 14:59:44

标签: web-services

我在行webrequest.create(v_strURL)

中得到一个空引用异常
Dim objHttpWebRequest As HttpWebRequest
        Dim objHttpWebResponse As HttpWebResponse
        Dim objRequestStream As Stream = Nothing
        Dim objResponseStream As Stream = Nothing

        Dim objXMLReader As XmlTextReader

        objHttpWebRequest = CType((WebRequest.Create(v_strURL)), HttpWebRequest) ''This line throws exception.

Url是正确的,并且确实给出了正确的答案。

0 个答案:

没有答案