1、把BaucheOcxLib.dll复制到foxtable安装目录,注册这个dll。:https://www.baidu.com/baidu?word=注册ocxhttp://www.foxtable.com/bbs/dispbbs.asp?BoardID=2&ID=124462&skin=0
3、试试,
全局代码
public AxBaucheOcx1 as AxBaucheOcxLib.AxBaucheOcx()
添加一个窗口,afterload事件
AxBaucheOcx1 = New AxBaucheOcxLib.AxBaucheOcx()
AxBaucheOcx1.Enabled = True
AxBaucheOcx1.Location = New System.Drawing.Point(43, 26)
AxBaucheOcx1.Name = "AxBaucheOcx1"
AxBaucheOcx1.OcxState = CType(resources.GetObject("AxBaucheOcx1.OcxState"), System.Windows.Forms.AxHost.State)
AxBaucheOcx1.Size = New System.Drawing.Size(662, 496)
AxBaucheOcx1.TabIndex = 0
e.form.panel.Controls.Add(AxBaucheOcx1)
开启按钮
Dim i As Int32 = AxBaucheOcx1.CAM_Open(0, 1, 640, 480) '开启摄像头
If i = 0 Then
msgbox("开启成功")
Else
msgbox("开启失败!")
End If
[此贴子已经被作者于2020/3/24 20:00:21编辑过]