public static void Main(string[] args) { string filename; /* * Console.WriteLine("Enter filename with teacher info: "); * string tp = Console.ReadLine(); * Console.WriteLine("Enter filename with course names: "); * string cc = Console.ReadLine(); */ string tp = args[0]; string cc = args[1]; rs = new RoomSign(tp, cc); pe = new PeriodEntries(tp, cc); schoolsigns.Append(@"<style> @media print{.mysign {page-break-after:always;}} .rn{font-size:36pt;font-family:calibri;text-align:center;} td{border:1px solid black;font-size:14pt;height:50px; } table{width:100%;table-layout: fixed;padding-top:0px; padding-bottom:0px;} table.spaceUnder{border-collapse:separate; border-spacing: 0px 10px;}</style>" ); //Console.WriteLine("Enter a room number. Type in -1 to print all."); //string roomNumber = Console.ReadLine(); string roomNumber = args[2]; filename = roomNumber; if (roomNumber == "-1") { for (int index = 0; index < getDistinctRooms().Count; index++) { schoolsigns.Append(createPage(getDistinctRooms()[index])); } filename = "All_Room_Schedules"; } else { schoolsigns.Append(createPage(roomNumber)); schoolsigns.Append(createPage("206")); schoolsigns.Append(createPage("208")); } File.WriteAllText("test.html", schoolsigns.ToString()); File.WriteAllText("Room 307.doc", schoolsigns.ToString()); File.WriteAllText("rooms.txt", string.Join("\n", getDistinctRooms().ToArray())); //File.WriteAllText(filename + " " + DateTime.Today + ".html", schoolsigns.ToString()); //File.WriteAllText(filename + " " + DateTime.Today + ".doc", schoolsigns.ToString()); //getDistinctRooms().ForEach(i => Console.WriteLine(i)); //foreach(Entry e in entryList) // Console.WriteLine(e.ToString()); }
public RoomSign(string entryInfo, string courseCode) { PeriodEntries pe = new PeriodEntries(entryInfo, courseCode); organize(pe.getEntryList()); }
public static void Main(string[] args) { string filename; /* Console.WriteLine("Enter filename with teacher info: "); string tp = Console.ReadLine(); Console.WriteLine("Enter filename with course names: "); string cc = Console.ReadLine(); */ string tp = args[0]; string cc = args[1]; rs = new RoomSign(tp, cc); pe = new PeriodEntries(tp, cc); schoolsigns.Append(@"<style> @media print{.mysign {page-break-after:always;}} .rn{font-size:36pt;font-family:calibri;text-align:center;} td{border:1px solid black;font-size:14pt;height:50px; } table{width:100%;table-layout: fixed;padding-top:0px; padding-bottom:0px;} table.spaceUnder{border-collapse:separate; border-spacing: 0px 10px;}</style>"); //Console.WriteLine("Enter a room number. Type in -1 to print all."); //string roomNumber = Console.ReadLine(); string roomNumber = args[2]; filename = roomNumber; if(roomNumber == "-1"){ for(int index = 0; index < getDistinctRooms().Count; index++){ schoolsigns.Append(createPage(getDistinctRooms()[index])); } filename = "All_Room_Schedules"; }else{ schoolsigns.Append(createPage(roomNumber)); schoolsigns.Append(createPage("206")); schoolsigns.Append(createPage("208")); } File.WriteAllText("test.html", schoolsigns.ToString()); File.WriteAllText("Room 307.doc", schoolsigns.ToString()); File.WriteAllText("rooms.txt", string.Join("\n",getDistinctRooms().ToArray())); //File.WriteAllText(filename + " " + DateTime.Today + ".html", schoolsigns.ToString()); //File.WriteAllText(filename + " " + DateTime.Today + ".doc", schoolsigns.ToString()); //getDistinctRooms().ForEach(i => Console.WriteLine(i)); //foreach(Entry e in entryList) // Console.WriteLine(e.ToString()); }