摘要:
stringthePath="../../Upload/Star/";thePath=Server.MapPath(thePath);//得到文件绝对路径 System.IO.DirectoryInfod=newSystem.IO.DirectoryInfo(thePath);System.IO.DirectoryInfo[]ds=d.GetDirectories("*.*",System.IO.SearchOption.TopDirectoryOnly);foreach(System.IO.DirectoryInfovarinds){//路径全称 Re 阅读全文
摘要:
///<summary> ///图片上传 ///</summary> ///<paramname="TheFileName">保存的文件名称,不需要后缀</param> privateBooleanfileUploadImage(stringTheFileName){boolges=false;stringfile="";file=fileLogoUrl.PostedFile.FileName;string[]end=newstring[]{"jpg","gif",& 阅读全文
摘要:
///<summary> ///根据文件夹路径得到文件路径下所有的文件 ///</summary> ///<paramname="pathtext"></param> publicvoidListFiles(stringpathtext){try{if(pathtext==null||pathtext.Equals("")){Response.Write("路径不能为空错误");}else{//得到文件名,目录 string[]filename=Directory.GetFiles(Se 阅读全文