Esempio n. 1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void ModifyPopup_FormClosing(object sender, FormClosingEventArgs e)
        {
            DonationRecording parent = (DonationRecording)this.Owner;

            //DonationInformation parent = (DonationInformation)this.Owner;
            parent.getDataFromChildWindow(parentWinValue);
        }
Esempio n. 2
0
        private void btnGo_Click(object sender, EventArgs e)
        {
            if (txtDonorID.Text != string.Empty || txtDonorID.Text != "")
            {
                //DonationInformation parent = (DonationInformation)this.Owner;
                DonationRecording parent = (DonationRecording)this.Owner;
                var donorId     = txtDonorID.Text;
                var donorExists = donorRepositoy.checkModifyDonorIDExists(donorId);
                if (donorExists == null)
                {
                    MessageBox.Show("Entered Donor Id dosen't exist, kindly enter again to modify the record");
                    return;
                }
                //var selectedDonor = donors.Where(donor => donor.Id == donorId.Id).FirstOrDefault();
                parent.getDataFromChildWindow(donorExists);
                parentWinValue = parentWinValue + 1;
                this.Close();
            }

            else if (txtDonorName.Text != string.Empty || txtDonorName.Text != "")
            {
                //DonationInformation parent = (DonationInformation)this.Owner;
                DonationRecording parent = (DonationRecording)this.Owner;
                var donorName            = txtDonorName.Text;
                var donorExists          = donorRepositoy.checkModifyDonorNameExists(donorName);
                if (donorExists == null)
                {
                    MessageBox.Show("Entered Donor Name dosen't exist, kindly enter again to modify the record");
                    return;
                }
                //var selectedDonor = donors.Where(donor => donor.Id == donorId.Id).FirstOrDefault();
                parent.getDataFromChildWindow(donorExists);
                parentWinValue = parentWinValue + 1;
                this.Close();
            }

            else if (txtMRNO.Text != string.Empty || txtMRNO.Text != "")
            {
                //DonationInformation parent = (DonationInformation)this.Owner;
                DonationRecording parent = (DonationRecording)this.Owner;
                var donorName            = txtMRNO.Text;
                var donorExists          = donorRepositoy.checkModifyMRNoExists(donorName);
                if (donorExists == null)
                {
                    MessageBox.Show("Entered MR Nnumber dosen't exist, kindly enter again to modify the record");
                    return;
                }
                //var selectedDonor = donors.Where(donor => donor.Id == donorId.Id).FirstOrDefault();
                parent.getDataFromChildWindow(donorExists);
                parentWinValue = parentWinValue + 1;
                this.Close();
            }
            else
            {
                MessageBox.Show("Kindly enter data to modify the data");
                return;
            }
        }
 private void picBoxDonation_Click(object sender, EventArgs e)
 {
     if (oModuleMaprepo.isAuthorized(ApplicationElements.loggedInEmployee.Role, 1, "Donation") == 1)
     {
         DonationRecording odonationRecording = new DonationRecording();
         odonationRecording.ShowDialog();
     }
     else
         MessageBox.Show("You are not authorised to view this module.. Please contact administrator");
 }
Esempio n. 4
0
 private void masterToolStripMenuItem_Click(object sender, EventArgs e)
 {
     formDispose();
     oDonorReprt          = new DonorMasterReportUI();
     oDonorReprt.TopLevel = false;
     pnlBody.Controls.Add(oDonorReprt);
     oDonorReprt.Location    = new Point(150, 100);
     oDonationRecording      = new DonationRecording();
     oDonationRecording.Size = new Size(557, 422);
     oDonorReprt.Show();
 }
 private void masterToolStripMenuItem_Click(object sender, EventArgs e)
 {
     formDispose();
     oDonorReprt = new DonorMasterReportUI();
     oDonorReprt.TopLevel = false;
     pnlBody.Controls.Add(oDonorReprt);
     oDonorReprt.Location = new Point(150, 100);
     oDonationRecording = new DonationRecording();
     oDonationRecording.Size = new Size(557, 422);
     oDonorReprt.Show();
 }
 private void pictureBox2_Click(object sender, EventArgs e)
 {
     DonationRecording odonationRecording = new DonationRecording();
     odonationRecording.ShowDialog();
 }