GetEnumList
Top  Previous  Next

Description

Returns the array of string values representing the specified enumerated feature of the camera.


Syntax


[VB]
Value=objActiveGige.GetEnumList( Name )


[C/C++]
HRESULT GetEnumList( bstr Name, VARIANT* pInfo );


Data Types
[VB]

Name: String
Return value
: Variant (Array)


Parameters
[C/C++]

Name [in]  
String containing the name of the enumerated feature  
pInfo [out,retval]  
Pointer to the SAFEARRAY containing the allowed string values of the feature:  
 
Return Values

S_OK  
Success  
E_NOINTERFACE        
Feature does not exist or not available  
E_INVALIDARG  
Feature is not of enumerated type  
E_FAIL  
Failed to read feature.  


Example


This VB example uses a combo box to switch between different auto exposure modes:

Private Sub
 Form_Load()
Lst = ActiveGige1.GetEnumList("ExposureAuto")
For
 i = 0 
To
 
UBound
(Lst)
Combo1.AddItem (Lst(i))
Next

Combo1.ListIndex = ActiveGige1.GetFeature("ExposureAuto")
ActiveGige1.Acquire = 
True
End Sub

Private Sub
 Combo1_Click()
ActiveGige1.SetFeatureString Combo1.Text
End Sub


Remarks

The index of an element in the string list can be used as an argument of SetFeature to set a specific value for the feature.

Note that in C/C++ applications it is required to call SafeArrayDestroy() to delete the SAFEARRAY returned by GetEnumList.

If the specified feature is not of the enumerated type or not supported by the camera, the method will return an error.