| | |
| | | procedure TCB_IMGPSScanX.PM103Click(Sender: TObject); |
| | | begin |
| | | if TreeView1.Selected = nil then Exit; |
| | | |
| | | {if Treeview1.Selected = NewTreeNode then |
| | | begin |
| | | ShowMessage('AAAAA'); |
| | | end; |
| | | if Treeview1.Selected = MyTreeNode1 then |
| | | begin |
| | | ShowMessage('BBBBB'); |
| | | end; |
| | | |
| | | if Treeview1.Selected = MyTreeNode2 then |
| | | begin |
| | | ShowMessage('CCCCC'); |
| | | end; |
| | | |
| | | if Treeview1.Selected = MyTreeNode3 then |
| | | begin |
| | | ShowMessage('DDDDD'); |
| | | end; |
| | | } |
| | | if (Treeview1.Selected = NewTreeNode) {or (Treeview1.Selected = MyTreeNode1)} then |
| | | begin |
| | | //ShowMessage('NewScanBtnClick'); |
| | | NewScanBtnClick(self) |
| | | end |
| | | Else |
| | | begin |
| | | //ShowMessage('AddScanBtnclick'); |
| | | AddScanBtnclick(self); |
| | | end; |
| | | end; |
| | | |
| | | procedure TCB_IMGPSScanX.PM104Click(Sender: TObject); |
| | |
| | | Str2Dir(ScanPath); |
| | | |
| | | ScanDocDir := FindLastestDocDir(ScanCaseno,DocNo); |
| | | if DocNoNeedDiv(DocNo) then //要分份數 |
| | | |
| | | if DocNoNeedDiv(DocNo)then //要分份數 |
| | | begin |
| | | //Showmessage(DocNo+#13+FormCode2Page(FormID)+#13+inttostr(GetDocDir_Page(ScanCaseno,ScanDocDir))+#13+ScanDocDir); |
| | | if ((FormCode2Page(FormID) = '01') and (GetDocDir_Page(ScanCaseno,ScanDocDir)>0)) or (ScanDocDir = '') then |
| | |
| | | FormID := NowGuideFormID; |
| | | DocNo := FormCode2DocNo(FormID); |
| | | ScanDocDir := FindLastestDocDir(ScanCaseno,DocNo); |
| | | if DocNoNeedDiv(DocNo) then //要分份數 |
| | | //ShowMessage('ScanDocDir='+ScanDocDir); |
| | | if (DocNoNeedDiv(DocNo)) then //要分份數 |
| | | begin |
| | | if ((FormCode2Page(FormID) = '01') and (GetDocDir_Page(ScanCaseno,ScanDocDir)>0)) or (ScanDocDir = '') then |
| | | if TreeView1.Selected = MyTreeNode1 then //20170421 掃瞄插頁時選則在案號上才要分份數 選在FormID上就不分份數 |
| | | begin |
| | | ScanInfo.ImageCount := 0; |
| | | ScanDocDir := DocNo2DocNoDir(ImageSavePath + ScanCaseno+'\',DocNo); |
| | | if ((FormCode2Page(FormID) = '01') and (GetDocDir_Page(ScanCaseno,ScanDocDir)>0)) or (ScanDocDir = '') then |
| | | begin |
| | | ScanInfo.ImageCount := 0; |
| | | ScanDocDir := DocNo2DocNoDir(ImageSavePath + ScanCaseno+'\',DocNo); |
| | | end; |
| | | end; |
| | | end |
| | | Else //不分份數 |