简体   繁体   English

Delphi7客户端连接到WCF服务

[英]Delphi7 client connecting to WCF service

I have a WCF service and 2 clients I'm testing with. 我有WCF服务和2个正在测试的客户端。 The first client is written in c# .NET 3.5 and has no trouble connecting to the WCF service. 第一个客户端是用c#.NET 3.5编写的,连接到WCF服务没有问题。 The other client is written in Delphi7, and it's the one I'm interested in getting working. 另一个客户端是用Delphi7编写的,这是我感兴趣的一个客户端。 This is the interesting part. 这是有趣的部分。 If I start the service then hit it with the Delphi client, it won't connect... but if I start the service then hit it with the .Net client then try the Delphi client, it works ! 如果我启动该服务然后用Delphi客户端运行它,它将无法连接...但是,如果我启动该服务然后用.Net客户端运行它,然后尝试使用Delphi客户端,它将起作用! Could be something to do with the design-time addresses, I'm not sure. 我不确定这与设计时地址有关。 Maybe a more experienced person will know what's going on and what I need to do to get my Delphi client working without needing a .Net client running alongside it. 也许更有经验的人会知道正在发生什么以及我需要做什么才能使Delphi客户端正常工作,而无需同时运行.Net客户端。 It might be relevant to note that the service is currently being hosted in a winforms app. 可能需要注意的是,该服务当前托管在winforms应用程序中。

重新生成wsdl并将其重新导入到Delphi 7中似乎可以解决该问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM