Dim c As new camera c.capture() '开始照相 If c.image IsNot Nothing Then '照相成功 c.Save("d:\test.jpg") '保存文件 Dim ftp As new FTPClient ftp.Host = "222.***.***.***" ftp.Account = "**" ftp.Password = "**" Dim ftpname As String = "/" & Format(Date.Now, "yyyyMMddHHmmss") & ".jpg" If ftp.Upload("d:\test.jpg",ftpname) = True Then Tables("表A").Current("第一列") &= IIF(Tables("表A").Current.IsNull("第一列"), "", vbcrlf) & ftpname End If End If
|