예제 #1
0
        private void btnManageStudent_Click(object sender, EventArgs e)
        {
            CultureInfo nz = CultureInfo.GetCultureInfo("en-NZ"); //Change currency Symble to $ instead of €

            StudentListForm.ShowDialog();
            lblStudent.Text = ClsInstitute.StudentList.Count + " Student(s)";
            lblStudent.Text = string.Format(nz, "{0} Student(s)\nTotal Balance: {1:C}",
                                            ClsInstitute.StudentList.Count, ClsInstitute.TotalBalance());
        }
예제 #2
0
 private void btnClose_Click(object sender, EventArgs e)
 {
     try
     {
         ClsInstitute.Save();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
     Close();
 }
예제 #3
0
 public FrmMain()
 {
     InitializeComponent();
     try
     {
         ClsInstitute.Retrieve();
         lblStudent.Text = string.Format("{0} Student(s)\nTotal Balance: {1:C}",
                                         ClsInstitute.StudentList.Count, ClsInstitute.TotalBalance());
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }