标签:tar open ring http img 调用 str void string
练习WCF入库,添加了一个WCF项目,同时添加了一个控制台程序,在控制台程序启动时,调用WCF服务,报错。

控制台程序代码为:
namespace WcfConsumer
{
class Program
{
static void Main(string[] args)
{
using (ServiceHost serviceHost = new ServiceHost(typeof(testService))) {
serviceHost.Open();
Console.WriteLine("WCF Service has started...");
Console.ReadLine();
serviceHost.Close();
}
Console.WriteLine("The WCF Service has stopped...");
}
}
}
标签:tar open ring http img 调用 str void string
原文地址:http://www.cnblogs.com/shanheng/p/6118177.html