0

I am calling webservice eg http://www.example.com/xml/tempconvert.asmx .

This work fine but when i try this on my server machine it give

No connection could be made because the target machine actively refused it

my code is

HttpWebRequest req = WebRequest.Create(url) as HttpWebRequest;

            XmlDocument xmlDoc = new XmlDocument();
            using (HttpWebResponse resp = req.GetResponse() as HttpWebResponse)
            {
                xmlDoc.Load(resp.GetResponseStream());
            }

As it works on other machines so there is a problem in my server machine . I searched that it may be port block but I have already allowed from firewall port 80 .

So can any body figure out like above url even not open on my IE on server .

  • 1
    Possible duplicate of https://stackoverflow.com/questions/9695224/no-connection-could-be-made-because-the-target-machine-actively-refused-it-127-0 – er-sho Aug 16 '18 at 11:38
  • Where is your server? How did you configure site bindings on IIS? Without such, nobody can help. – Lex Li Aug 16 '18 at 17:18

0 Answers0