I have created and started WCF service on my development machine.
When I use http://localhost:8080/ServiceName/Function
as URL, works fine.
When I use http://MY.LAN.IP.ADDRESS:8080/ServiceName/Function
as URL, it is NOT working anywhere, not on development machine not on other machines in LAN.
For example, in Android test app, the error message says:
"Connection to http://... is refused"
I have disabled windows firewall and antivirus.
What is causing such problem? Do I need to configure something in service configuration (web.config)?
Note that service is running inside ASP.Net Development Server.
According to this site, you should check to see if the random port that the Development Server chooses (which, in your case would be 8080) is open on the firewall. If that doesn't work, then I'm not sure that it will work at all without a version of IIS installed and configured for these remote requests.
The ASP.NET Development Server cannot accept remote connections, so this won't work from outside of local machine
http://msdn.microsoft.com/en-us/library/58wxa9w5%28VS.80%29.aspx
I'm not sure how you have it configured; as that can actually cause complications. But your issue resides within your Host
. How your creating the Host
to receive your Proxies
. One thing that may be happening:
When it runs on your local machine it actually is enabling IIS Express
so you can view the service and test it. So at that moment IIS is handling those request. Which allows it to work without a problem.
The other dilemma are these:
That is more then likely what is happening. Since IIS is automatically handling it; one of those are more then likely not correct.
But until we see your app.config
and ServiceHost
code details we can't be for certain.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.