最简单的日志:

public class Logger
{
    public static void Trace(string title,string message)
    {
        string path = System.Windows.Forms.Application.StartupPath + "\\Log.txt";
 
        StreamWriter sw = new StreamWriter(path,true);
        sw.Write("{0}:{1}", title, message);
        sw.Flush();
        sw.Close();
    }
}

 

相关文章:

  • 2021-09-29
  • 2022-12-23
  • 2022-12-23
  • 2022-01-03
  • 2021-08-17
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-12-07
  • 2022-12-23
  • 2021-11-17
  • 2021-10-24
  • 2022-12-23
  • 2022-01-26
  • 2022-02-07
相关资源
相似解决方案