码迷,mamicode.com
首页 > Windows程序 > 详细

C#判断是否有某文件夹存在

时间:2017-01-23 14:56:46      阅读:210      评论:0      收藏:0      [点我收藏+]

标签:local   cal   substring   inf   c#   new   info   oca   cto   

DirectoryInfo directory = new DirectoryInfo(@"D:\0001\" + year + @"\" + time.Substring(4,2) + @"\" + LocaleId + @"\");
if (!directory.Exists)//不存在
directory.Create();

C#判断是否有某文件夹存在

标签:local   cal   substring   inf   c#   new   info   oca   cto   

原文地址:http://www.cnblogs.com/xwchengc/p/6343865.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!