(一)如果不存在路径就新建文件夹
string directory = @"C:\Users\Administrator\Desktop\温控数据\"; if (!Directory.Exists(directory)) { Directory.CreateDirectory(directory); }