예제 #1
0
        // #  --------------------   DBACTIONS ---------------------------
        private void addPayment()
        {
            if (lvManageRecord.CheckedItems.Count < 1)
            {
                frmOrPayDataEntry f = frmOrPayDataEntry.show_asAdd(new MsgHandler(RefreshData), this.lastOPNumber);
                if (f.hasUpdated)
                {
                    this.lastOPNumber = f.lastOPNumber;
                }
            }
            else
            {
                // instantiate an object of student
                Student st = new Student(lvManageRecord.CheckedItems[0].SubItems[1].Text);

                // pass values to form

                frmOrPayDataEntry.checkedItems = Payor.getCheckedItems(lvManageRecord);
                frmOrPayDataEntry.studentData  = st.studentData;


                frmOrPayDataEntry f = frmOrPayDataEntry.show_asAdd(new MsgHandler(RefreshData), this.lastOPNumber);

                if (f.hasUpdated)
                {
                    this.lastOPNumber = f.lastOPNumber;
                }
            }
        }
예제 #2
0
        private void btnSave_Click(object sender, EventArgs e)
        {
            if (listView1.CheckedItems.Count > 0)
            {
                checkedItems = Payor.getCheckedItems(listView1);


                Close();
            }
            else
            {
                MessageBox.Show("Please Select a particular");
            }
        }