Torna al Thread

if (this.clsDatiFileIniService.PathLog != "") { try { if (System.IO.Directory.Exists(this.clsDatiFileIniService.PathLog) == true) { using (StreamWriter w = File.AppendText(this.clsDatiFileIniService.PathLog + "\\STRUMETS_SERVICE_" + DateTime.Now.Day.ToString() + "_" + DateTime.Now.Month.ToString() + "_" + DateTime.Now.Year.ToString() + ".TXT")) { w.WriteLine(Properties.Settings.Default.NomeServizio + StringaDaLoggare); } } catch (Exception e) { writeEventLogWindows("Non riesco a scrivere nel file di log: " + e.Message, EventLogEntryType.Error ); this.Stop(); }
Copyright © dotNetHell.it 2002-2025
Running on Windows Server 2008 R2 Standard, SQL Server 2012 & ASP.NET 3.5