# NMS_V5ResetChannelStatistics

Resets the statistics collected for a specified HDLC channel provisioned on the active interface variant.

#### Prototype

NMS_V5_RESULT_T NMS_V5ResetChannelStatistics ( NMS_V5_INTERFACE_ID_T interfaceId, NMS_V5_CHANNEL_LOCATION_T *channel_loc)

Argument | Description
interfaceId | Interface ID of a provisioned interface.
channel_loc | Pointer to the HDLC channel location. typedef union _NMS_V5_CHANNEL_LOCATION_T { struct { DWORD boardNb; DWORD trunkNb; DWORD timeslotNb; } CG; }NMS_V5_CHANNEL_LOCATION_T See the Details section for field descriptions.

#### Return values

Return value | Description
NMSV5_SUCCESS |
NMSV5_INTERNAL_FAILURE | Internal failure. Refer to the trace log for more information.
NMSV5_INVALID_CHANNEL | Specified HDLC channel is not provisioned on this interface.
NMSV5_INVALID_INTERFACE_ID | Specified interface is not provisioned.
NMSV5_NOT_INITIALIZED | NMS V5 library was not initialized with NMS_V5Initialize.

#### Details

NMS_V5ResetChannelStatistics resets the statistics for the specified HDLC channel. To reset the statistics, the interface must be provisioned (with NMS_V5ProvisionInterface) and the HDLC channel must be configured on the active variant of the interface.

The NMS_V5_CHANNEL_LOCATION_T structure includes the following fields:

Field | Description
boardNb | Logical board number where an HDLC instance is located (as defined by NMS OAM).
trunkNb | Logical trunk number associated with the HDLC channel (as defined by NMS OAM).
timeslotNb | Physical timeslot associated with the HDLC channel.

#### See also

NMS_V5GetChannelStatistics

#### Example

void ResetChannelStatistics( void )
{
NMS_V5_RESULT_T NmsResult;
DWORD InterfaceId;
NMS_V5_CHANNEL_LOCATION_T ChannelLocation;
printf("NMS_V5ResetChannelStatistics:\n");
/* Get parameters */
promptdw_nodft("Enter InterfaceId", &InterfaceId);
printf("Enter channel location:\n");
GetChannelLocationNMS( &ChannelLocation );
NmsResult = NMS_V5ResetChannelStatistics (InterfaceId,
ChannelLocation);
printf ("NMS_V5ResetChannelStatistics:
Result=%s\n",PRINT_RESULT(NmsResult));
}