Exemplo n.º 1
0
        protected override ResultStatus Export()
        {
            if (!StartExport())
            {
                return(ResultStatus.Fail);
            }

            string lsFile = PbFunc.wf_copy_file(_ProgramID, "30396");

            Workbook workbook = new Workbook();

            //載入Excel
            workbook.LoadDocument(lsFile);
            try {
                b30396 = new B30396(workbook, emMonth.Text);

                ShowMsg("30396-「BRF」期貨契約價量資料 轉檔中...");
                OutputShowMessage = b30396.Wf30396();
                ShowMsg("30398abc-「BRF」期貨契約價量資料(買賣方比重) 轉檔中...");
                OutputShowMessage = b30396.Wf30396abc();
            }
            catch (Exception ex) {
                File.Delete(lsFile);
                WriteLog(ex);
                return(ResultStatus.Fail);
            }
            finally {
                //存檔
                workbook.SaveDocument(lsFile);
                EndExport();
            }
            return(ResultStatus.Success);
        }
Exemplo n.º 2
0
 public void Wf30396abcTest()
 {
    string isCorrect = b30396.Wf30396abc();
    Assert.IsNotNull(isCorrect);
 }