IService1.cs
[OperationContract]
string SendMessage(string[] contact, string message,CookieContainer con);
服务1.svc.cs
string SendMessage(string[] contact, string message,CookieContainer con);
{
.... .....
....
... code
}
客户端
string[] contact;
svc.SendMessageCompleted += new EventHandler<SendMessageCompletedEventArgs>(svc_Send_Sms);
svc.SendMessageAsync(contact, txtsms.Text,con);
这给出了错误
'SmsApplication.ServiceReference1.Service1Client.SendMessageAsync(System.Collections.ObjectModel.ObservableCollection, string, System.Net.CookieContainer)' 的最佳重载方法匹配有一些无效参数
参数 1:无法从 'string[]' 转换为 'System.Collections.ObjectModel.ObservableCollection'