这是一个非常初学者的问题,但我不熟悉如何使用 HttpContext.Current.Request.Files
假设我的 webService Url 是:
http://127.0.0.1/iisEntry/myApi.asmx
有人可以快速编写一些关于如何将文件上传到以下网络方法的代码吗?
public void AddDocument(String title)
{
var action = new AddDocumentAction
{
File = HttpContext.Current.Request.Files[0],
DocumentTitle = title
}
processor.Process(action);
}