您需要使用System.IO.File.Delete而不是System.IO.Delete
string path = "~/Pics/Image1.jpg";
System.IO.File.Delete(Server.MapPath(path))
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
13213 次 |
最近记录: |