本文介绍了VB6将Cam Capture保存到文件中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好。请允许任何人告诉我在这段代码中出错的地方。我连接了一个网络摄像头,通过此代码捕获图片。当我执行代码时,它不会将其保存到我设置的文件和文件夹路径中。它提供了c:\ my Documents Save对话框。


(代码)

私有子mnuSaveFrame_Click()

Dim FileName As String

Dim retVal As Boolean


filter:=" DIB位图文件(* .bmp)| * .bmp",_

DlgTitle:="保存图片",_

DefaultExt:=" bmp",_

所有者:= Me.hWnd)


如果错误<> retVal然后

retVal = capFileSaveDIB(hCapWnd,FileName)

如果为True<> retVal然后

MsgBox问题保存框架,vbInformation,App.Title

结束如果

结束如果


结束子


谢谢

Hi everyone. Please could anyone tell me where I am going wrong in this code. I have a webcam connected that captures the a pic through this code. When I execute the code it does not save it to the file and folder path I have set. It comes up with the c:\my Documents Save dialog box.

(Code)
Private Sub mnuSaveFrame_Click()
Dim FileName As String
Dim retVal As Boolean

retVal = VBGetSaveFileName(FileName = "c:\Program files\Sg\Pic Men\Men1.bmp", _
filter:="DIB Bitmap Files (*.bmp)|*.bmp", _
DlgTitle:="Save Picture", _
DefaultExt:="bmp", _
Owner:=Me.hWnd)

If False <> retVal Then
retVal = capFileSaveDIB(hCapWnd, FileName)
If True <> retVal Then
MsgBox "Problem saving frame", vbInformation, App.Title
End If
End If

End Sub

Thanks

推荐答案





它不使用默认的cam软件,它是完全独立的运行vb应用程序。也可以创建AVI等。

It does not use the default cam software, it is completely standalone operational vb application. Can also create AVI etc.


这篇关于VB6将Cam Capture保存到文件中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-14 18:50