Interpreting Return Codes
lgo_EventMessage()
Retrieve a human-readable sring describing an event.
#include "laygomsg.h"
LMessage lgo_EventMessage
(
LEvent event
);
| event | event code to retrieve description of |
lgo_EventMessage() retrieves a human-readable string describing an event code returned by lgo_Poll() or lgo_Event().
All calls to lgo_EventMessage() are successful. If the event code is not defined, the message "LayGO event code not defined" is returned.
if ((event = lgo_Poll(cid, &bufferSize)) < 0)
{
/* handle error condition */
}
else
{
msgString = lgo_EventMessage(event);
printf("Event waiting on CID %d: '%s'\n",
cid, msgString;
}