1 /// <summary>
2 /// Logs string to text file.
3 /// Private helper method.
4 /// </summary>
5 /// <param name="textToLog">The text logged to file.</param>
6 private static void Log(string textToLog)
7 {
8 TextWriter tw = File.AppendText(@"C:\Log.txt");
9 tw.WriteLine(DateTime.Now + ":\t" + textToLog);
10 tw.Close();
11 }