Calling Web Page from Windows Service
- by David Moorhouse
I have a Windows 2008 server. This has an instance of IIS7 installed and a website, accessible only via an internal hostname defined in the the servers hosts file.
e.g. the server IP is 10.0.6.11 and the hosts file contains an entry
10.0.6.11 hl7.ourname.org
I would like to call a URL on the website, e.g "http://hl7.ourname.org/updatestatus" from a Windows service.
I can call the web site from an instance of IE7 running on the server. However, if try to call it from a Windows service I get a "Socket Error # 10061 Connection refused."
This looks like a permission issue. The service is running as "Network Service" ,but maybe I should be running as a different user.
Thanks