SnmpCountVbl

[This is preliminary documentation and subject to change.]

A WinSNMP manager application calls the WinSNMP SnmpCountVbl function to enumerate the variable binding entries in the specified variable bindings list.

SNMPAPI_STATUS SnmpCountVbl(
  HSNMP_VBL vbl   // handle to the variable bindings list 
);
 

Parameters

vbl
Handle to the variable bindings list to enumerate.

Return Values

If the function succeeds, the return value is the count of variable binding entries in the variable bindings list.

If the function fails, the return value is SNMPAPI_FAILURE. To get extended error information, call SnmpGetLastError. The SnmpGetLastError function can return one of the following errors.

Error Code Description
SNMPAPI_NOT_INITIALIZED The SnmpStartup function did not complete successfully.
SNMPAPI_ALLOC_ERROR An error occurred during memory allocation.
SNMPAPI_NOOP The variable bindings list does not contain any variable binding entries at this time.
SNMPAPI_VBL_INVALID The vbl parameter is invalid.
SNMPAPI_OTHER_ERROR An unknown or undefined error occurred.

Remarks

The SnmpCountVbl function returns an unsigned integer value that is the maximum value the WinSNMP manager application can specify for the index parameter in the SnmpGetVb, SnmpSetVb, and SnmpDeleteVb functions.

QuickInfo

  Windows NT: Requires version 5.0 or later. Available as a redistributable for Windows NT 4.0.
  Windows: Unsupported.
  Windows CE: Unsupported.
  Header: Declared in winsnmp.h.
  Import Library: Use wsnmp32.lib.

See Also

WinSNMP Manager API Overview, WinSNMP Functions, SnmpGetVb, SnmpSetVb, SnmpDeleteVb