我正在使用 Visual Studio 2012 制作 Web Service 。我已经编写了 Web 服务的代码,但是当我尝试通过将其添加为服务参考(通过粘贴 Web 服务的运行 URL)在新网站中使用它时。它给出了以下错误:
"There was an error downloading 'http://localhost:3849/WebService3/WebService.asmx/_vti_bin/ListData.svc/$metadata'.
Unable to connect to the remote server
No connection could be made because the target machine actively refused it 127.0.0.1:3849
Metadata contains a reference that cannot be resolved: 'http://localhost:3849/WebService3/WebService.asmx'.
There was no endpoint listening at http://localhost:3849/WebService3/WebService.asmx that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
Unable to connect to the remote server
No connection could be made because the target machine actively refused it 127.0.0.1:3849
If the service is defined in the current solution, try building the solution and adding the service reference again."
我应该怎么办?