Exemplo n.º 1
0
        static void populate_ocValuesForInsert(List <string> ocValues, object DTO)
        {
            ThisDTO oThisDTO = (ThisDTO)DTO;

            ocValues.Add(oThisDTO.GameDate.ToString());
            ocValues.Add(oThisDTO.LeagueName.ToString());
        }
Exemplo n.º 2
0
        public void InsertRow()
        {
            ThisDTO oThisDTO = populateDTO();

            //                        TableName  ColNames(csv)  DTO             Insert into DTO Method
            SqlFunctions.DALInsertRow(TableName, TableColumns, oThisDTO, populate_ocValuesForInsert, _ConnectionString);
        }
Exemplo n.º 3
0
        private ThisDTO populateDTO()
        {
            ThisDTO oThisDTO = new ThisDTO();

            oThisDTO.LeagueName = _oLeagueDTO.LeagueName;
            // ...
            return(oThisDTO);
        }
Exemplo n.º 4
0
        static void populateDTOFromRdr(List <object> ocRows, object oRow, SqlDataReader rdr)
        {
            // Column Updates Procedure
            // 1) Update Table Columns
            // 2) Select 1000, Cut Column names, Insert in Textpad, run Sql Columns macro, Replace {table}Columns with macro Op
            // 3) Use CodeGeneration.xlsm to generate populateBoxScoreValues entries
            // 4) Update CoversBoxScore.PopulateBoxScoresDTO

            ThisDTO oLeagueDTO = (ThisDTO)oRow;

            oLeagueDTO.LeagueName = rdr["LeagueName"].ToString().Trim();
            oLeagueDTO.RotNum     = (int)rdr["RotNum"];
            // DateTime double
            //  oLeagueDTO.MultiYearLeague = (bool)rdr["MultiYearLeague"];
        }
Exemplo n.º 5
0
        public int GetRow(ThisDTO oThisDTO)
        {
            int rows = SysDAL.DALfunctions.ExecuteSqlQuery(_ConnectionString, getRowSql(), null, oThisDTO, populateDTOFromRdr);

            return(rows);
        }