标签:using sage ted private sys 创建 line mes color
private static void setlog(string message) { string logPath = System.AppDomain.CurrentDomain.BaseDirectory + "\\log\\"; if (!Directory.Exists(logPath))//没有则创建 { Directory.CreateDirectory(logPath); } using (FileStream stream = new FileStream(logPath + DateTime.Now.ToString("yyyyMMddHHmm") + ".txt", FileMode.Append)) using (StreamWriter writer = new StreamWriter(stream)) { writer.WriteLine($"{DateTime.Now}:{message}"); } }
标签:using sage ted private sys 创建 line mes color
原文地址:https://www.cnblogs.com/Mzg121584668/p/11322940.html