Exemple #1
0
        public void LoadAssesOtherFeesSTRAND_ICT()
        {
            //clear list
            otherFees.Clear();
            dgvOtherFees.Rows.Clear();
            //pass value to list
            otherFees = otherFee.Load();

            //loop through load it to list view
            if (Strand.Equals("TVL - ICT"))
            {
                Strand = "STEM";
            }
            foreach (var item in otherFees)
            {
                if (item.Strand.Equals(Strand))
                {
                    dgvOtherFees.Rows.Add(item.OtherFeeName, item.OtherFeeAmount);


                    foreach (var item2 in otherFees)
                    {
                        if (item.Strand.Equals("Non-STEM"))
                        {
                            dgvOtherFees.Rows.Add(item2.OtherFeeName, item2.OtherFeeAmount);
                        }
                    }
                }

                if (item.Strand.Equals("Non-STEM"))
                {
                    dgvOtherFees.Rows.Add(item.OtherFeeName, item.OtherFeeAmount);
                }
            }

            double sum = 0;

            for (int i = 0; i < dgvOtherFees.Rows.Count; i++)
            {
                sum += Convert.ToDouble(dgvOtherFees.Rows[i].Cells[1].Value);
            }
            lblOther.Text = sum.ToString("n");
            Strand        = "TVL - ICT";
        }
Exemple #2
0
        public void LoadRecords()
        {
            //clear list

            dgvOtherFee.Rows.Clear();
            otherFees.Clear();

            //pass value to list
            otherFees = otherFee.Load();

            //loop through load it to list view
            foreach (var item in otherFees)
            {
                //Load to datagridView
                dgvOtherFee.Rows.Add(item.Id, item.OtherFeeName, item.OtherFeeAmount);
            }
        }//End LoadRecords()