Sending data stream messages to a client

An Open Server application can send a message to a client. To perform this function, the application:

  1. Calls srv_msg with cmd set to CS_SET and msgidp pointing to the buffer containing the message ID.

    A *statusp value of SRV_HASPARAMS indicates that the message has parameters. A value of SRV_NOPARAMS indicates that the message has no parameters.

    For more information see srv_msg.

  2. Calls srv_descfmt, srv_bind, and srv_xferdata to describe and send each parameter.

An Open Server application can send messages from within any event handler except the SRV_ATTENTION, SRV_CONNECT, SRV_DISCONNECT, SRV_URGDISCONNECT, and SRV_START handlers.