# oamBoardEnum

Lists the names of all boards in the NMS OAM database.

#### Prototype

DWORD oamBoardEnum ( CTAHD ctahd, int ixBoard, char *szName, DWORD dwNameSize )

Argument | Description
ctahd | [in] Context handle.
ixBoard | [in] Board index.
szName | [out] Pointer to buffer containing board name.
dwNameSize | [in] Size of szName (maximum number of bytes to return, including final null character).

#### Return values

Return value | Description
SUCCESS |
CTAERR_BAD_ARGUMENT | szName is NULL or 0.
CTAERR_SVR_COMM | Natural Access Server is not running.
OAMERR_NOT_ENOUGH_MEMORY | Specified dwNameSize is insufficient.
OAMERR_NOT_FOUND | ixBoard is out of range.
OAMERR_SERVER_NOT_RUNNING | Supervisor is shut down.

#### Details

oamBoardEnum lists the names of all boards that exist as managed objects. This list matches the list of boards in the Supervisor keyword Boards[x].

To use oamBoardEnum, pass an index value starting at 0 and continue until the function returns OAMERR_NOT_FOUND.

For more information, see Retrieving board information.

#### Example

// List all the board names.
int const dwNameSize = 128;
char szName[ dwNameSize ];
for (int ixBoard=0; SUCCESS == oamBoardEnum( ctahd, ixBoard, szName,
dwNameSize ); ++ixBoard)
printf( "%s\n", szName );