/// <summary>
/// 日志记录
/// </summary>
/// <param name="MessageBox"></param>
/// <param name="configPathName">配置文件中记录日志的配置名称</param>
public static void WirteLog(string MessageBox)
{
string LogPath = ConfigurationManager.AppSettings["Credit_Log_Path"].ToString().Trim();
if (!Directory.Exists(LogPath))
{
Directory.CreateDirectory(LogPath);
}
//写入日志
StreamWriter sr = new StreamWriter(LogPath + "\\" + "PayLog" + DateTime.Now.ToString("yyyyMMdd") + ".txt", true);
sr.WriteLine(DateTime.Now.ToString("HH:mm:ss") + " " + MessageBox);
sr.Close();
}