以下是例子中的代码,打开文件后文件的路径与foxtable程序的路径一致,怎么才能把打开的文件存放在指定目录中
If Tables("员工").Current Is Nothing Then
Return
End If
Dim dr As DataRow = Tables("员工").Current.DataRow
Dim pts() As String = dr.SQLGetValue("信息").Split("|")
Dim fl As String = ProjectPath & dr("_Identify") & "." & pts(0)
If FileSys.FileExists(fl) AndAlso CRCCheckFile(fl) = pts(1) Then '如果本地存在同名文件且CRC校验值相同
'则直接使用本地文件
Else
'否则从数据库提取文件
If dr.SQLLoadFile("附件",fl) = False Then '如果提取文件失败
Messagebox.Show("附件提取失败,可能并不存在附件!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information)
Return
End If
End If
Dim Proc As New Process '打开文件
Proc.File = fl
Proc.Start()