Beispiel #1
0
        /// <summary>
        /// Get dates with data and fill the global dataset of dates with it
        /// </summary>
        private void FillDatesUsingData(DateTime visibleDate)
        {
            try
            {

                ScoringDAL dbAccess = new ScoringDAL();
                String selectedMonth = visibleDate.Month.ToString();
                String selectedYear = visibleDate.Year.ToString();
                dsPrevDateSelectedData = dbAccess.GetDatesWithData(selectedMonth,
                                        selectedYear, (hifModel.Value == "") ?
                                        "Risk View" : hifModel.Value);
                ViewState["selectedPrevDateDataForMonth"] = dsPrevDateSelectedData;

            }
            catch (Exception ex)
            {
                //StreamWriter swException = new StreamWriter(
                // @"C:\Users\parevi01\Documents\Visual Studio 2012\Projects " + 
                // @"\ScoringApp1\ScoringApp1\Log\ScoringFormExcpetions.txt");
                //swException.WriteLine(DateTime.Now.ToString() + "-" + ex.GetType() + "-" + ex.Message + "-" + ex.StackTrace);
                //swException.Close();
                // throw;
            }

        }
Beispiel #2
0
        /// <summary>
        /// Get dates with data and fill the global dataset of dates with it
        /// </summary>
        private void FillDatesUsingData(DateTime visibleDate)
        {
            try
            {

                ScoringDAL dbAccess = new ScoringDAL();
                String selectedMonth = visibleDate.Month.ToString();
                String selectedYear = visibleDate.Year.ToString();

                //getting dates that have data - default value for model is taken as "Risk View"
                dsPrevDateSelectedData = dbAccess.GetDatesWithData(selectedMonth,
                                        selectedYear, (hifModel.Value == "") ?
                                        "Risk View" : hifModel.Value, (hifVersion.Value == "") ?
                                        "4" : hifVersion.Value, (mode_id.SelectedValue == "") ?
                                        "XML" : mode_id.SelectedValue);

                //this data is stored and sent as view state variables
                ViewState["selectedPrevDateDataForMonth"] = dsPrevDateSelectedData;

            }
            catch (Exception ex)
            {
                //StreamWriter swException = new StreamWriter(
                // @"C:\Users\parevi01\Documents\Visual Studio 2012\Projects " + 
                // @"\ScoringApp1\ScoringApp1\Log\ScoringFormExcpetions.txt");
                //swException.WriteLine(DateTime.Now.ToString() + "-" + ex.GetType() + "-" + ex.Message + "-" + ex.StackTrace);
                //swException.Close();
                // throw;
            }

        }