Exemple #1
0
        private void btnHome_Click(object sender, RoutedEventArgs e)
        {
            try
            {
                if (sFormName == "HomeMember")
                {
                    frmHomeMembership frm = new frmHomeMembership();
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "Registration")
                {
                    frmMemberRegistration frm = new frmMemberRegistration(0);
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "PostArrear")
                {
                    frmArrearPost16 frm = new frmArrearPost16(0);
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "PreArrear")
                {
                    frmArrearPre16 frm = new frmArrearPre16(0);
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "Resingation")
                {
                    frmResingation frm = new frmResingation(0);
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "Transfer")
                {
                    frmTransfer frm = new frmTransfer(0);
                    this.Close();
                    frm.ShowDialog();
                }
                else if (sFormName == "LEVY")
                {
                    frmLevy frm = new frmLevy(0);
                    this.Close();
                    frm.ShowDialog();
                }

                else if (sFormName == "TDF")
                {
                    frmTDF frm = new frmTDF(0);
                    this.Close();
                    frm.ShowDialog();
                }
            }
            catch (Exception ex)
            {
                ExceptionLogging.SendErrorToText(ex);
            }
        }
Exemple #2
0
        private void dgvDetails_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            try
            {
                //if ((sFormName == "Registration" || sFormName == "LEVY" || sFormName == "TDF" || sFormName == "Resingation" ||
                //    sFormName == "Transfer" || sFormName == "PostArrear" || sFormName == "PreArrear" || sFormName == "HomeMember" ||
                //    sFormName== "Annual Statement") && (dgvDetails.SelectedItem != null))

                if ((dgvDetails.SelectedItem != null))
                {
                    DataRowView drv = (DataRowView)dgvDetails.SelectedItem;
                    dMember_Code = Convert.ToDecimal(drv["MEMBER_CODE"]);
                    if (dMember_Code != 0)
                    {
                        if (sFormName == "Transfer")
                        {
                            frmTransfer frm = new frmTransfer(dMember_Code);
                            frm.Show();
                            this.Hide();
                        }
                        else if (sFormName == "PostArrear")
                        {
                            frmArrearPost16 frm = new frmArrearPost16(dMember_Code, 0);
                            frm.Show();
                            this.Hide();
                        }
                        else if (sFormName == "PreArrear")
                        {
                            frmArrearPre16 frm = new frmArrearPre16(dMember_Code, 0);
                            frm.Show();
                            this.Hide();
                        }
                        else if (sFormName == "Resingation")
                        {
                            frmResingation frm = new frmResingation(dMember_Code);
                            frm.Show();
                            this.Hide();
                        }
                        else if (sFormName == "LEVY")
                        {
                            frmLevy frm = new frmLevy(dMember_Code);
                            frm.Show();
                            this.Close();
                        }

                        else if (sFormName == "TDF")
                        {
                            frmTDF frm = new frmTDF(dMember_Code);
                            frm.Show();
                            this.Close();
                        }
                        else if (sFormName == "Annual Statement")
                        {
                            Reports.frmAnnualStatement frm = new Reports.frmAnnualStatement(dMember_Code);
                            frm.Show();
                            this.Close();
                        }
                        else
                        {
                            frmMemberRegistration frm = new frmMemberRegistration(dMember_Code, false);
                            frm.Show();
                            this.Hide();
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                ExceptionLogging.SendErrorToText(ex);
            }
        }