コード例 #1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="FilePath">Excel_Template</param>
 public B30790(string FilePath, string StartDate, string EndDate, string TxStartDate, string TxEndDate)
 {
     _lsFile          = FilePath;
     _startDateText   = StartDate;
     _endDateText     = EndDate;
     _txStartDateText = TxStartDate;
     _txEndDateText   = TxEndDate;
     dao30790         = new D30790();
 }
コード例 #2
0
        protected override ResultStatus AfterOpen()
        {
            base.AfterOpen();
            string   lsYMD = new D30790().MaxDate();
            DateTime date;

            if (!string.IsNullOrEmpty(lsYMD))
            {
                if (lsYMD.Length == 8)
                {
                    date = lsYMD.AsDateTime("yyyyMMdd");
                }
                else if (lsYMD.Length == 6)
                {
                    date = lsYMD.AsDateTime("yyyyMM");
                }
                else
                {
                    date = DateTime.MinValue;
                }

                emEndDate.DateTimeValue = date;
            }
            else
            {
                return(ResultStatus.Fail);
            }

            if (date != DateTime.MinValue)
            {
                emStartDate.DateTimeValue = PbFunc.relativedate(date, -6);
            }

            emStartDate.Focus();
            emTxEndDate.DateTimeValue = date;
            return(ResultStatus.Success);
        }
コード例 #3
0
        public void MaxDateTest()
        {
            string data = new D30790().MaxDate();

            Assert.IsNotNull(data);
        }