private static void TestNotifyService() { NotifyService.NotifyServiceClient client = new NotifyService.NotifyServiceClient(); while (true) { string txt = Console.ReadLine(); if (!"quit1".Equals(txt, StringComparison.OrdinalIgnoreCase)) { client.SendSimpleMessage("zhangweixing", txt); } } }
static void Main(string[] args) { try { NotifyService.NotifyServiceClient client = new NotifyService.NotifyServiceClient(); while (true) { string txt = Console.ReadLine(); string[] list=client.SysCommand("star", txt); Console.WriteLine("total:{0}", list.Length); foreach (var item in list) { Console.WriteLine(item); } } } catch (Exception) { throw; } }