January 12th, 2010, 04:33 AM
Accessing Webservice from HttpWebRequest
I am using the below code to access the webservice in my vbscript. When it executes popup screen appears for me to enter username and password.
Set mHTTP = New MSXML2.XMLHTTP
mHTTP.Open "GET", WebseriveURL, False, "<CURRENT_USER>"
The same code i would like to convert in dotnet Csharp, i have written a below code but not able to get the popup message screen to input the username and password whereas i get 401 not authorized error
System.Net.HttpWebRequest wReq = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(WebserviceURL);
wReq.Method = "GET
System.Net.HttpWebResponse wr = (System.Net.HttpWebResponse)wReq.GetResponse();
Please help me to get the popup in dotnet
Click Here to Expand Forum to Full Width
This is a CodeGuru survey question.