Error While calling webservice
Hi All, I am trying to call GetList method of Sharepoint but when I call this webmethod I am getting below error. I am using this URL to call web service. http://<Servername>/_vti_bin/Lists.asmx The HTTP request is unauthorized with client authentication scheme 'Negotiate'. The authentication header received from the server was 'NTLM'. Our sharepoint site is using windows authentication. My code is as below WebApplication2.SharepointList.GetListRequest objGetListRequest = new GetListRequest(); WebApplication2.SharepointList.ListsSoapClient objListsSoapClient = new ListsSoapClient(); objListsSoapClient.Endpoint.Address = new System.ServiceModel.EndpointAddress("http://Servername/_vti_bin/Lists.asmx"); objListsSoapClient.ClientCredentials.Windows.ClientCredential = System.Net.CredentialCache.DefaultNetworkCredentials; objListsSoapClient.ClientCredentials.Windows.AllowedImpersonationLevel = System.Security.Principal.TokenImpersonationLevel.Impersonation; objListsSoapClient.GetList("Form Templates"); Please let me know what should I do to solve this error. Thanks in advance Regards, Kaivan Shah
May 18th, 2011 10:30am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics