メールサーバーの外部から添付ファイルを取得してそこから送信するWebサービスを構築しようとしていますが、エラー:IEnumerableから継承する型は、Add(System.Object)の実装を持たなければなりません。
To be XML serializable, types which inherit from IEnumerable must have an implementation of Add(System.Object) at all levels of their inheritance hierarchy. System.Collections.Specialized.StringDictionary does not implement Add(System.Object). [InvalidOperationException: There was an error reflecting type 'System.Net.Mail.Attachment'.]
私のコードは次のようなものです:
[WebMethod]
public String SendMailWithAttachment(string mail_sender, string[] mail_receiver, string mail_subject, string mail_text, Attachment att)
...
ありがとう、これはうまくいきました。 –