Предоставленная схема URI «https» недействительна; ожидаемый http при вызове веб-службы

Я пытаюсь вызвать веб-службу SharePoint из рабочего процесса CRM, используя пользовательский код C #. Однако, когда я запускаю свой код, я получаю следующую ошибку:

The provided URI scheme 'https' is invalid; expected 'http'. Parameter name: via

Вот оскорбительный код:

#region Set up security binding and service endpoint
BasicHttpBinding binding = new BasicHttpBinding(BasicHttpSecurityMode.TransportCredentialOnly);
binding.Security.Transport.ClientCredentialType = HttpClientCredentialType.Ntlm;
binding.Security.Transport.ProxyCredentialType = HttpProxyCredentialType.Ntlm;
EndpointAddress endpoint = new EndpointAddress(endpointAddress);
#endregion

#region Create the client and supply appropriate credentials
CopySPContents.CopyService.SharepointFileServiceClient client = new CopySPContents.CopyService.SharepointFileServiceClient(binding, endpoint);              
client.ClientCredentials.Windows.ClientCredential = System.Net.CredentialCache.DefaultNetworkCredentials;
client.ClientCredentials.Windows.AllowedImpersonationLevel = System.Security.Principal.TokenImpersonationLevel.Impersonation;              
#endregion

#region Call the web service and trace its response
String response = client.CopyFolderContentsAcrossSites(sourceSiteURL, sourceFolderURL, destinationSiteURL, destinationFolderURL);
#endregion

Ошибка брошена на линииString response = client.CopyFolderContentsAcrossSites(sourceSiteURL, sourceFolderURL, destinationSiteURL, destinationFolderURL); где метод клиента вызывается.

Спасибо за любую помощь,
Скотт

Ответы на вопрос(1)

Ваш ответ на вопрос