My Student Project: C# for Beginners : Assignment #4 (Series)
Permission to publish my code submitted for the project assignment was granted by the professor.
This is a very simple windows form application that I completed for a class assignment. It is shown here to illustrate my coding style, structure, and commenting. This example is considered Level 1 – Easy.
The main objectives of this assignment are:
• To learn using one-dimensional arrays.
• To learn how to write and use properties to access values saved in the private fields of an object.
In addition, exercise more with strings and also learn to use a ListBox for display of results. Keep the presentation of data (interaction with the user, input/output) from the logics behind data processing.
Apu (a user) is often asked to manage and organize parties. He would like to have a simple application that lists the names of the people to be invited to a party and also get an idea of the total cost based on an estimated cost per guest. We use a form object (MainForm) for the GUI and a class Party to contain the logic pertaining to party arrangements. For saving the names of the guests, use a one dimensional array of strings in the Party class. MainForm declares a variable of the Party class as its field. We refer to this object as party (with a small p).
MainForm should handle all the interactions (input/output) between the user and the application, and it should not contain logics that is (or can be) a part of the Party class’ responsibility. Every logic concerning the party, except processing of input and display of output, should be coded in the Party class.
My Solution Code
You can view and download the GitHub repository here.
You can also download a zip archive of the project code here.