开发者

Not able to connect https server using SharpSvn in C# , Could not connect to server error

开发者 https://www.devze.com 2023-03-21 19:10 出处:网络
I am developing Windows application in VS2010. I am using SharpSVN to connect with subversion repository. I have tried to get the repository items using svnClient.GetList(targetUri, out list); functio

I am developing Windows application in VS2010. I am using SharpSVN to connect with subversion repository. I have tried to get the repository items using svnClient.GetList(targetUri, out list); function. It is working fine for local(file\\:) repository. When I try to connect the https server, it is giving error.

I have used to sample https server given in codespeces. I have tried in tortoiseSVN also to connect. It is saying "could not connect to server". And I have tried through C# and getting the same error.

Please see below for https server url and username and password

https://svn.codespaces.com/cw/com_codespaces_api_net

username: api_guest
password Password1

below code I have used to connect.

using (SvnClient svnClient = new SvnClient())
  {
svnClient.Authentication.DefaultCredentials = new System.Net.NetworkCredential("api_guest", "Pa开发者_如何学Pythonssword1");

                SvnTarget targetUri = new SvnUriTarget(new Uri(sourcePath));
                var list = new Collection<SvnListEventArgs>();                
                svnClient.GetList(targetUri, out list);
}

Error Message:

OPTIONS of 'https://svn.codespaces.com/cw/com_codespaces_api_net': could not connect to server (https://svn.codespaces.com)"

I have searched for solution in Google. I am not able to find any help.

0

精彩评论

暂无评论...
验证码 换一张
取 消