Example #1
0
        public void AMLACIFRisk()
        {
            try
            {
                MySqlCommand     cmd = new MySqlCommand();
                MySqlDataAdapter da  = new MySqlDataAdapter();
                DataSet          DS  = new DataSet();
                DataTable        DT  = new DataTable();
                AMLA_CIF_Risk = new AMLACIFRisk();
                //Ind_Summary_NoData = new crIndividualSummaryNoData();

                GlobalVariable.MyADOConnection = new MySqlConnection(GlobalVariable.dbConnectionString);
                GlobalVariable.MyADOConnection.Open();

                //MySQLQuery = "";
                //MySQLQuery = "call Client_Summary_Crystal ('" + GlobalVariable.Date_ + "'); ";

                //MySqlCommand cmd = new MySqlCommand(MySQLQuery, GlobalVariable.MyADOConnection);
                //cmd.ExecuteScalar();

                cmd             = new MySqlCommand("sp_DAV_AMLA_CIF_Risk", GlobalVariable.MyADOConnection);
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.Parameters.AddWithValue("Date_", GlobalVariable.Date_);
                cmd.CommandTimeout = 0;
                da.SelectCommand   = cmd;
                da.Fill(DS, "TABLE");

                //if (DS.Tables[0].Rows.Count == 0)
                //{
                //    Ind_Summary_NoData.SetDataSource(DS.Tables[0]);
                //    GlobalVariable.MyADOConnection.Close();
                //    crViewer.ReportSource = Ind_Summary_NoData;
                //}
                //else
                //{
                //    Ind_Summary.SetDataSource(DS.Tables[0]);
                //    GlobalVariable.MyADOConnection.Close();
                //    crViewer.ReportSource = Ind_Summary;
                //}

                AMLA_CIF_Risk.SetDataSource(DS.Tables[0]);
                GlobalVariable.MyADOConnection.Close();
                crViewer.ReportSource = AMLA_CIF_Risk;

                DT = DS.Tables["TABLE"];

                GlobalForms.Form1.DataTab = new DataTable();
                GlobalForms.Form1.DataTab = DS.Tables["TABLE"];

                //GlobalForms.Form1.CreateCSVFile(DT, "d:\\Depositor_Summary.csv");


                frmReports rep = new frmReports();
                rep.Dispose();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Example #2
0
        public void Client_Individual_Crystal()
        {
            try
            {
                MySqlCommand     cmd = new MySqlCommand();
                MySqlDataAdapter da  = new MySqlDataAdapter();
                DataSet          DS  = new DataSet();
                DataTable        DT  = new DataTable();
                Individual        = new crIndividual();
                Individual_NoData = new crIndividualNoData();

                GlobalVariable.MyADOConnection = new MySqlConnection(GlobalVariable.dbConnectionString);
                GlobalVariable.MyADOConnection.Open();
                string DateHold = GlobalVariable.Date_;
                //MySQLQuery = "";
                //MySQLQuery = "call Client_Individual ('" + DateHold + "'); ";

                //MySqlCommand cmd = new MySqlCommand(MySQLQuery, GlobalVariable.MyADOConnection);
                //cmd.ExecuteScalar();

                cmd             = new MySqlCommand("sp_dav_Client_Individual", GlobalVariable.MyADOConnection);
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.Parameters.AddWithValue("Date_", DateHold);
                cmd.CommandTimeout = 0;
                da.SelectCommand   = cmd;
                da.Fill(DS, "TABLE");

                if (DS.Tables[0].Rows.Count == 0)
                {
                    Individual_NoData.SetDataSource(DS.Tables[0]);
                    GlobalVariable.MyADOConnection.Close();
                    crViewer.ReportSource = Individual_NoData;
                }
                else
                {
                    Individual.SetDataSource(DS.Tables[0]);
                    GlobalVariable.MyADOConnection.Close();
                    crViewer.ReportSource = Individual;
                }

                DT = DS.Tables["TABLE"];

                //GlobalForms.Form1.CreateCSVFile(DT, "d:\\Depositor_Report.csv");


                frmReports rep = new frmReports();
                rep.Dispose();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Example #3
0
        public void Deposits_Type()
        {
            try
            {
                MySqlCommand     cmd = new MySqlCommand();
                MySqlDataAdapter da  = new MySqlDataAdapter();
                DataSet          DS  = new DataSet();
                DataTable        DT  = new DataTable();
                Deposit_Type_Summary = new crDepositTypeSummary();
                //TopDepositor = new crTopDepositor();
                //TopDepositor_NoData = new crTopDepositorNoData();

                GlobalVariable.MyADOConnection = new MySqlConnection(GlobalVariable.dbConnectionString);
                GlobalVariable.MyADOConnection.Open();

                //MySQLQuery = "";
                //MySQLQuery = "call sp_Top_Depositor ('" + GlobalVariable.Date_ + "'); ";

                //MySqlCommand cmd = new MySqlCommand(MySQLQuery, GlobalVariable.MyADOConnection);
                //cmd.ExecuteScalar();

                cmd             = new MySqlCommand("sp_DAV_Deposit_Type_Summary", GlobalVariable.MyADOConnection);
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.Parameters.AddWithValue("Date_", GlobalVariable.Date_);
                cmd.CommandTimeout = 0;
                da.SelectCommand   = cmd;
                da.Fill(DS, "TABLE");

                if (DS.Tables[0].Rows.Count == 0)
                {
                    //TopDepositor_NoData.SetDataSource(DS.Tables[0]);
                    //GlobalVariable.MyADOConnection.Close();
                    //crViewer.ReportSource = TopDepositor_NoData;
                }
                else
                {
                    Deposit_Type_Summary.SetDataSource(DS.Tables[0]);
                    GlobalVariable.MyADOConnection.Close();
                    crViewer.ReportSource = Deposit_Type_Summary;
                }

                frmReports rep = new frmReports();
                rep.Dispose();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Example #4
0
        public void Sched_Dep_Size_Est_Ins_Dep()
        {
            try
            {
                MySqlCommand     cmd = new MySqlCommand();
                MySqlDataAdapter da  = new MySqlDataAdapter();
                DataSet          DS  = new DataSet();
                DataTable        DT  = new DataTable();
                Est_Ins_Dep        = new crSched_Dep_Size_Est_Ins_Dep();
                Est_Ins_Dep_NoData = new crSched_Dep_Size_Est_Ins_DepNoData();

                GlobalVariable.MyADOConnection = new MySqlConnection(GlobalVariable.dbConnectionString);
                GlobalVariable.MyADOConnection.Open();

                //MySQLQuery = "";
                //MySQLQuery = "call sp_Sched_Dep_Size_Est_Ins_Dep ('" + GlobalVariable.Date_ + "'); ";

                //MySqlCommand cmd = new MySqlCommand(MySQLQuery, GlobalVariable.MyADOConnection);
                //cmd.ExecuteScalar();

                cmd             = new MySqlCommand("sp_dav_Sched_Dep_Size_Est_Ins_Dep", GlobalVariable.MyADOConnection);
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.Parameters.AddWithValue("Date_", GlobalVariable.Date_);
                cmd.CommandTimeout = 0;
                da.SelectCommand   = cmd;
                da.Fill(DS, "TABLE");

                if (DS.Tables[0].Rows.Count == 0)
                {
                    Est_Ins_Dep_NoData.SetDataSource(DS.Tables[0]);
                    GlobalVariable.MyADOConnection.Close();
                    crViewer.ReportSource = Est_Ins_Dep_NoData;
                }
                else
                {
                    Est_Ins_Dep.SetDataSource(DS.Tables[0]);
                    GlobalVariable.MyADOConnection.Close();
                    crViewer.ReportSource = Est_Ins_Dep;
                }
                frmReports rep = new frmReports();
                rep.Dispose();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }