Cannot Connect to Remote Server

L

leeo

This is driving me absolutely mad. We've been using this code to
connect to a remote site:

System.Net.ServicePointManager.CertificatePolicy = New
cCertificatePolicy

wr = CType(WebRequest.Create(goSettings.NHSDPBClaimsURL),
HttpWebRequest)
nc = New NetworkCredential(goSettings.NHSUserName,
goSettings.NHSPassword)
wr.Credentials = nc
wr.ContentType = "text/xml"
wr.Method = "POST"

xw = New XmlTextWriter(wr.GetRequestStream(), Nothing)

When the goSettings.NHSDPBClaimsURL in the webrequest statement is set
to https://ebusiness.dpb.nhs.uk/claims.asp it all works absolutely
fine. However I'm being asked to send the same data to a different
server at the location which is referred to as
https://195.212.12.173/claims.asp. However whenever we try this it
simply errors when it tries to perform the GetRequestStream and says it
can't connect to the remote server (even though we can use IE to access
it easily. We've tried all the usual things like creating our
certificate policy to get around any security certificates but nothing
has worked.

Please, if anyone has ANY suggestions can you let me know.
 
L

leeo

Forget this. We've fixed the problem, and it was to do with the
Security Policy certificate.

Madness aborted.
 
L

leeo

Forget this. We've fixed the problem, and it was to do with the
Security Policy certificate.

Madness aborted.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top