Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/wcf/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Castle Windsor Wcf设施:端点名称问题_Wcf_Windsor Facilities - Fatal编程技术网

Castle Windsor Wcf设施:端点名称问题

Castle Windsor Wcf设施:端点名称问题,wcf,windsor-facilities,Wcf,Windsor Facilities,我的应用程序正在尝试使用我有WSDL文件的Web服务。因此,我使用SvcUtil.exe从中生成了一个接口。我在课堂上使用的方法如下: namespace ApplicationUsage { public class Usage { private readonly IExportService _exportServiceProxyClient; public Usage(IExportToNavisionService _exportSer

我的应用程序正在尝试使用我有WSDL文件的Web服务。因此,我使用SvcUtil.exe从中生成了一个接口。我在课堂上使用的方法如下:

namespace ApplicationUsage
{
    public class Usage
    {
        private readonly IExportService _exportServiceProxyClient;

        public Usage(IExportToNavisionService _exportServiceProxyClient)
        {
            _exportServiceProxyClient= exportServiceProxyClient;
        }
}
我将“IExportService”注入为:

我不知道如何回避这个问题。为什么Windsor希望端点名称应与注入它的类的构造函数中的变量名称相同


有人能帮忙吗?

您只有一个端点吗?如果是这样,只需将端点设为默认值:Yes。我只有一个端点。如何将其设为默认值?
Component.For<IExportService >()     .AsWcfClient(DefaultClientModel.On(WcfEndpoint.FromConfiguration("exportServiceProxyClient")));
**Could not find endpoint element with name 'exportServiceProxyClient' and contract 'IExportService ' in the ServiceModel client configuration section. 
This might be because no configuration file was found for your application, or because no endpoint element matching this name could be found in the client element.**