CameraPlugged
Top  Previous  Next

Description

This event is fired each time a GigE Vision™ camera is connected to the system .


Syntax


[VB]
Private Sub objActiveGige_CameraPlugged(ByVal Camera As Integer)


[C/C++]
HRESULT Fire_CameraPlugged(SHORT Camera);


Data Types
[VB]

Camera: Integer  


Parameters
[C/C++]

Camera  
The index of the camera that has been connected.  
 

Return Values


S_OK  
Success  
E_FAIL  
Failure.  


Example


This VB example uses the CameraPlugged and CameraUnplugged events to detect changes in the number of GigE Vision™ cameras in the network:

Private Sub ActiveGige1_CameraPlugged(ByVal Camera As Integer)  
Dim Msg As String  
Msg = "Camera #" + Str(Camera) + " has been connected"  
MsgBox Msg  
End Sub  
 
Private Sub ActiveGige1_CameraUnplugged(ByVal Camera As Integer)  
Dim Msg As String  
Msg = "Camera #" + Str(Camera) + " has been disconnected"  
MsgBox Msg  
End Sub