PROTOCOL_STATE

CAS Tags
The PROTOCOL_STATE string tag appears in port information taglists retrieved from the server with the GET_PORTS_INFO function, or in message taglists retrieved from the fax server's sending or receiving queues with the GET_Q_ENTRIES_INFO function.  The tag describes a port's current activity.

The PROTOCOL_STATE tag can be set to one of the following strings:
Idle Idle
Dialing Off-hook and dialing
Answering Off-hook and answering the line
Transmitting Sending fax image data
Receiving Receiving fax image data
Pre Message Negotiating the connection prior to sending a fax page
Post Message Negotiating the connection after sending a fax page
Disconnecting Disconnecting

 
  Type Max Size Multiple Allowed
String N/A No

Example:
function GetPortProtocolState( PortName )
  {
  var Tl, ProtocolState;

  ProtocolState = "";

  Tl = CAS.New();
  CAS.AddTag(Tl,"GET_PORTS_INFO","");
  CAS.AddTag(Tl,"REGISTERED_NAME",REGISTERED_NAME.value);
  CAS.AddTag(Tl,"REGISTERED_PASSWORD",REGISTERED_PASS.value);
    // Request info for this port only
  CAS.AddTag(Tl,"PORT_NAME",PortName);
    // Send on this already open session 
  Tl = CAS.Send(Instance,Tl);
          
    // We only requested info for one port, so open the first
    // sub-section and get the state
  if (Sl = CAS.OpenSection(Tl,"PORT_NAME"))
    {
    ProtocolState = CAS.GetTag(Sl,"PROTOCOL_STATE",0);

    CAS.CloseSection(Sl);
    }

  return( ProtocolState);
  }

See Also:
GET_PORTS_INFO, GET_Q_ENTRIES_INFO