Tables("收文登记表").Current.Save() Dim Proc As New Process Proc.File = "C:\Windows\twain_32\WinMage\C100\Capture Tool.exe" Proc.Start() Proc.WaitForExit() Dim path As String = "C:\Users\Administrator\My Documents\My Scan\" Dim r As Row = Tables("收文登记表").Current Dim t As Integer = r("文件总页数") Dim i As Integer = 1 For Each file As String In FileSys.GetFiles(path) msgbox(file) r("文书图片") = r("文书编号") & "_" & i & ".jpg" & vbcrlf FileSys.CopyFile(file, ProjectPath & "Attachments\" & r("文书图片"),True) i += 1 Next
|