【发布时间】:2012-10-02 09:47:34
【问题描述】:
我想知道是否有任何属性或方法可以让我知道服务器上有一个文件夹。
就像我的 web.config 中有这个:
<appSettings>
<add key="ImagePath" value="http://server1:801/ImageById/"/>
</appSettings>
我得到这个钥匙是这样的:
var URL = System.Configuration.ConfigurationManager.AppSettings["ImagePath"].ToString();
现在我想知道如何访问服务器上的 imageById 并将某些内容保存到其中。 就像下面这样:
if("Folder exist on this server URL that is ImageById")
{
save images to the folder thorugh code of WCF as the folder has write permission.
}
我希望 WCF 中的此功能而不是 ASP.NET 中的功能。
请帮忙。
【问题讨论】:
-
您的意思是客户端可以检查服务器上是否存在文件夹吗?
标签: c# wcf web-config httpwebrequest