내 이전 질문은 wcf를 편안한 서비스로 바꿔 놓았습니다. convert a WCF Service, to a RESTful application?, 어떤 도움을 받아야합니다!wcf/rest를 청취하는 엔드 포인트 없음
하지만 내 클라이언트에서 새로운 문제로 실행하고 있습니다 :
화면 덤프에서 볼 수 있듯이There was no endpoint listening at http://localhost:26535/Service1.svc that could accept the message.
This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
이제 편안한 서비스를 실행 :
그리고 추가 할 수 있습니다 url의 값 1은 다음과 같습니다.
,그러나 아직 내가 비주얼 스튜디오의 또 다른 새로운 인스턴스에서 실행하는 것 어차피 내 클라이언트의 app.config는 다음과 같습니다
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<bindings>
<customBinding>
<binding name="WebHttpBinding_IService1">
<textMessageEncoding maxReadPoolSize="64" maxWritePoolSize="16"
messageVersion="Soap12" writeEncoding="utf-8">
<readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
</textMessageEncoding>
<httpTransport></httpTransport>
</binding>
</customBinding>
</bindings>
<client>
<endpoint address="http://localhost:26535/Service1.svc" binding="customBinding" bindingConfiguration="WebHttpBinding_IService1"
contract="ServiceReference1.IService1" name="WebHttpBinding_IService1" />
</client>
</system.serviceModel>
</configuration>
클라이언트 코드 :
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
}
public ServiceReference1.Service1Client testClient = new ServiceReference1.Service1Client();
private void button1_Click(object sender, EventArgs e)
{
label1.Text = testClient.GetData(Convert.ToInt32(textBox1.Text));
}
}
}
내가 이전 문제보고 있었다 이 지역의 여기에서 : WCF - "There was no endpoint listening at..." error
그러나 해결책을 제공하지 않습니까? IIS에 대한 호스팅에 익숙하지 않거나 그렇지 않은 경우에는 디버그 (F5)에서 작동하는 것이 좋을 것입니다.
내부 예외는 무엇입니까? 그것은 이것에 대해 더 많은 것을 밝힐 수 있습니다. –
내부 예외를 수행하면 원격 서버에서 오류를 반환했습니다. (404) 찾을 수 없습니다. –