Adding a menu item to the menu of the calendar


Calendar Assignment

Task:

For the third part of the assignment, a few more pieces of functionality will be added. Each piece added will add a feature that applies one of the subjects covered lately in class. One such feature will be the ability for the calendar to store events for printing in the calendar squares. This feature will implement arrays. Another feature added will be functionality to read in events from a file and insert them into the events array. Finally, the calendar will be expanded to include the ability to print a month calendar draw to a file. This will use file output.

Task one:

Event Planning This task will involve adding a menu item to the menu of the calendar. When the command "ev" is entered, a new action should be started. The event planning action should prompt the user for an event. The event should be entered in the form of "MM/DD event_title". After parsing the event, should be stored in a global array that will contain all events planned for that year. Event array should be a multidimensional array. It should be size 12(number of months in a year), with each sub array being large enough hold a single event for every day for the month. For example eventArray[11].length == 30 for year 2016. Once the event is parsed and stored, if the month calendar is drawn that contains scheduled events, those events should be presented in the calendar. If there is an event in a day, the title of the event should be placed within the blank space within the square of the day.

Task two:

File Reading Now that event planning is in place, if an event file exists, events should be read into the calendar when the calendar is first loaded. When the calendar starts, it will look for a file by the name "calendarEvents.txt". If that file is in the same directory as the program, the calendar will read in the events in the file. Given the event that the event file does not exist, no events will be read into the events array. Either the given example events file or an events file by the same name of your creation can be used to populate the calendar events. The events in the file must be of the form as entered events from the keyboard ("MM/DD event_title"). Events from the file will be read into the same events array from the first task. Once the calendar is drawn, events for the month should be placed within the appropriate dates squares, just like in the first task.

Task three:

File printing For this task, the calendar will be printing the same thing that it might to the screen but this time it will be printing to a file. This includes the asci art for a month. Add a new command "fp" to the menu. Once this command has been entered, the user will be prompted to enter a month to print. After the month to print has been obtained, the program should proceed to ask the user for the name of a file to which it will print the calendar. The program will next proceed to print the calendar with the appropriate events into the file. Make sure the file is closed once writing is completed.

Format your assignment according to the following formatting requirements:

1. The answer should be typed, double spaced, using Times New Roman font (size 12), with one-inch margins on all sides.

2. The response also includes a cover page containing the title of the assignment, the student's name, the course title, and the date. The cover page is not included in the required page length.

3. Also include a reference page. The Citations and references should follow APA format. The reference page is not included in the required page length.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Adding a menu item to the menu of the calendar
Reference No:- TGS03024750

Expected delivery within 24 Hours