protected override ResultStatus Export() { if (!StartExport()) { return(ResultStatus.Fail); } MessageDisplay message = new MessageDisplay(); string saveFilePath = PbFunc.wf_copy_file(_ProgramID, "43030"); try { b43030 = new B43030(saveFilePath, emDate.Text); ShowMsg("43030-上市證券保證金概況表 轉檔中..."); message.OutputShowMessage = b43030.Wf43030(); if (string.IsNullOrEmpty(message.OutputShowMessage)) { ShowMsg("轉檔有錯誤!"); if (File.Exists(saveFilePath)) { File.Delete(saveFilePath); } return(ResultStatus.Fail); } } catch (Exception ex) { ShowMsg("轉檔有錯誤!"); if (File.Exists(saveFilePath)) { File.Delete(saveFilePath); } WriteLog(ex); return(ResultStatus.Fail); } finally { EndExport(); } return(ResultStatus.Success); }
public void Setup() { b43030 = new B43030(destinationFilePath, "2014/10/20"); //b43030 = new B43030(destinationFilePath, "2017/12/19"); }