# tibemsSession_CreateTextMessage

Function

## Purpose

Create a text message.

## C Declaration

    tibems_status tibemsSession_CreateTextMessage(
        tibemsSession session,
        tibemsTextMsg* textMsg );

    tibems_status tibemsSession_CreateTextMessageEx(
        tibemsSession session,
        tibemsTextMsg* textMsg
        const char* text );

## COBOL Call

    CALL "tibemsSession_CreateTextMessage"
         USING BY VALUE session,
               BY REFERENCE textMsg,
               RETURNING tibems-status
    END-CALL.

    CALL "tibemsSession_CreateTextMessageEx"
         USING BY VALUE session,
               BY REFERENCE textMsg,
               BY REFERENCE text,
               RETURNING tibems-status
    END-CALL.

Note: `session` and `textMsg` have usage pointer.

## Parameters

Parameter | Description
--- | ---
`session` | Create the message in this session.
`textMsg` | Store the new message object in this location.
`text` | Create a text message with this text as its body.

## Remarks

The JMS specification requires these calls. It is equivalent to `tibemsTextMsg_Create`.

## See Also

`tibemsTextMsg`

Copyright © Cloud Software Group, Inc. All rights reserved.