在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
string lstrFileFolder = HttpContext.Current.Server.MapPath(Com.Common.m_folderData);
System.IO.Directory.Move("源目录","新目录"); string subFolder = System.DateTime.Today.AddDays(-1).ToString("yyMMdd"); string newFolder = System.DateTime.Today.ToString("yyMMdd"); string path = lstrFileFolder + subFolder; //判断目录是否存在,存在则改名 if (Directory.Exists(path)) } OR 项目->引用 浏览 COM组件 Microsoft Scripting Runtime , Scripting.FileSystemObject fso=new Scripting.FileSystemObjectClass(); fso.GetFolder("目录").Name="新目录名"; |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论