# CmtGetErrorMessage

int CmtGetErrorMessage (int cmtStatusCode, char cmtStatusMessage[]);

## Purpose

Converts a CmtStatus error code into a meaningful message string.

If the error code is kCmtSystemError, this function gets the message string from the operating system for the specific error that occurred.

## Parameters

Input
Name | Type | Description
cmtStatusCode | integer | A CmtStatus code returned from a LabWindows/CVI Utility Library multithreading function.
Output
Name | Type | Description
cmtStatusMessage | char [] | Returns a meaningful message string for a CmtStatus code.
| Note You must pass a char array that contains at least CMT_MAX_MESSAGE_BUF_SIZE (256) bytes.

## Return Value

Name | Type | Description
CmtStatus | integer | The CmtStatus code that the function call returns. This function returns 0 to indicate success and negative values to indicate failure. Pass the CmtStatus code to CmtGetErrorMessage to get a description of the error code.