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()); }
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); } }