Programming Guide



sm_msgfind

Finds a message given its number

#include <smerror.h>
char *sm_msgfind(int msg_id);

msg_id
Specifies the message to get.

Returns

Description

sm_msgfind finds the message specified by number and returns the message string. Unlike sm_msg_get, this function returns NULL if the message number is not found.

Message numbers for Panther messages are defined in smerror.h.

Example

#include <smdefs.h>
#include <smerror.h>

/* print out message #4 */

sprintf(buf, "The message reads: %s\n", sm_msgfind
(SM_BADKEY));
sm_fquiet_err(0, buf);

See Also

sm_msg_get, sm_msg_read