Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This message is sent when the state of a line device has changed. The application can invoke lineGetLineDevStatusto determine the new status of the line.

Syntax

LINE_LINEDEVSTATE 

dwDevice = (DWORD) 
hLine;

dwCallbackInstance = (DWORD) 
hCallback;

dwParam1 = (DWORD) 
DeviceState; 

dwParam2 = (DWORD) 
DeviceStateDetail1;

dwParam3 = (DWORD) 
DeviceStateDetail2;

Parameters

dwDevice

Handle to the line device. This parameter is NULL when dwParam1is LINEDEVSTATE_REINIT.

dwCallbackInstance

Callback instance supplied when opening the line. If the dwParam1parameter is LINEDEVSTATE_REINIT, the dwCallbackInstanceparameter is not valid and is set to zero.

dwParam1

Value that specifies the line device status item that has changed. It can be a combination of the following LINEDEVSTATE. The following table shows the values the parameter can take.

Value Description

LINEDEVSTATE_OTHER

Device status items other than those listed below have changed. The application should check the current device status to determine which items have changed.

LINEDEVSTATE_RINGING

The switch tells the line to alert the user. Service providers notify applications on each ring cycle by sending messages containing this constant. For example, in the United States, service providers send a message with this constant every six seconds.

LINEDEVSTATE_CONNECTED

The line was previously disconnected and is now connected to TAPI.

LINEDEVSTATE_DISCONNECTED

This line was previously connected and is now disconnected from TAPI.

LINEDEVSTATE_MSGWAITON

The message waiting indicator is turned on.

LINEDEVSTATE_MSGWAITOFF

The message waiting indicator is turned off.

LINEDEVSTATE_NUMCOMPLETIONS

The number of outstanding call completions on the line device has changed.

LINEDEVSTATE_INSERVICE

The line is connected to TAPI. This happens when TAPI is first activated, or when the line wire is physically plugged in and in service at the switch while TAPI is active.

LINEDEVSTATE_OUTOFSERVICE

The line is out of service at the switch or physically disconnected. TAPI cannot be used to operate on the line device.

LINEDEVSTATE_MAINTENANCE

Maintenance is being performed on the line at the switch. TAPI cannot be used to operate on the line device.

LINEDEVSTATE_OPEN

The line has been opened by another application.

LINEDEVSTATE_CLOSE

The line has been closed by another application.

LINEDEVSTATE_NUMCALLS

The number of calls on the line device has changed.

LINEDEVSTATE_TERMINALS

The terminal settings have changed.

LINEDEVSTATE_ROAMMODE

The roaming state of the line device has changed.

LINEDEVSTATE_BATTERY

The battery level has changed significantly (cellular).

LINEDEVSTATE_SIGNAL

The signal level has changed significantly (cellular).

LINEDEVSTATE_DEVSPECIFIC

The line's device-specific information has changed.

LINEDEVSTATE_REINIT

Items have changed in the configuration of line devices. To become aware of these changes (as with the appearance of new line devices), the application should reinitialize its use of TAPI. The dwDeviceparameter is left NULL for this state change as it applies to any of the lines in the system.

LINEDEVSTATE_LOCK

The locked status of the line device has changed. (For more information, refer to the description of the LINEDEVSTATUSFLAGS_LOCKED bit of the LINEDEVSTATUSFLAGS_ constants.)

LINEDEVSTATE_CAPSCHANGE

Indicates that, due to configuration changes made by the user or other circumstances, one or more of the members in the LINEDEVCAPSstructure for the address have changed. The application should use the lineGetDevCapsfunction to read the updated structure.

LINEDEVSTATE_CONFIGCHANGE

Indicates that configuration changes have been made to one or more of the media devices associated with the line device. The application, if it desires, can use the lineGetDevConfigfunction to read the updated information.

LINEDEVSTATE_TRANSLATECHANGE

Indicates that, due to configuration changes made by the user or other circumstances, one or more of the members in the LINETRANSLATECAPSstructure have changed. The application should use the lineGetTranslateCapsfunction to read the updated structure.

LINEDEVSTATE_COMPLCANCEL

Indicates that the call completion identified by the completion identifier contained in parameter dwParam2of the LINE_LINEDEVSTATE message has been externally canceled and is no longer considered valid.

LINEDEVSTATE_REMOVED

Indicates that the device is being removed from the system by the service provider (most likely through user action, through a control panel or similar utility). Normally, a LINE_LINEDEVSTATE message with this value is immediately followed by a LINE_CLOSE (TAPI)message on the device. Subsequent attempts to access the device prior to TAPI being reinitialized result in LINEERR_NODEVICE being returned to the application. If a service provider sends a LINE_LINEDEVSTATE message containing this value to TAPI, TAPI passes it along to applications that have negotiated TAPI 1.4 or later; applications negotiating a previous API version do not receive any notification.

dwParam2

Specifies the interpretation of this parameter depends on the value of dwParam1. If dwParam1is LINEDEVSTATE_RINGING, dwParam2contains the ring mode with which the switch instructs the line to ring. Valid ring modes are numbers in the range one to dwNumRingModes, where dwNumRingModesis a line device capability.

If dwParam1is LINEDEVSTATE_REINIT, and the message was issued by TAPI as a result of translation of a new TAPI message into a REINIT message, then dwParam2contains the dwMsgparameter of the original message.

If dwParam2is zero, this indicates that the REINIT message is a real REINIT message that requires the application to call the lineShutdownfunction at its earliest convenience.

dwParam3

Value that specifies the interpretation of this parameter depending on the value of dwParam1. If dwParam1is LINEDEVSTATE_RINGING, dwParam3contains the ring count for this ring event. The ring count starts at zero.

If dwParam1is LINEDEVSTATE_REINIT, and the message was issued by TAPI as a result of translation of a new API message into a REINIT message, then dwParam3contains the dwParam1parameter of the original message. For example, dwParam3will contain LINEDEVSTATE_TRANSLATECHANGE or some other LINEDEVSTATE constant, if dwParam2isLINE_LINEDEVSTATE, or it will create the new device identifier, if dwParam2is LINE_CREATE).

Return Value

None.

Remarks

The sending of the LINE_LINEDEVSTATE message can be controlled with lineSetStatusMessages. An application can indicate status item changes about which it wants to be notified. By default, all status reporting is disabled except for LINEDEVSTATE_REINIT, which cannot be disabled. This message is sent to all applications that have a handle to the line, including those that called the lineOpenfunction with the dwPrivilegesparameter set to LINECALLPRIVILEGE_NONE, LINECALLPRIVILEGE_OWNER, LINECALLPRIVILEGE_MONITOR, or permitted combinations of these.

The dwParam1parameter does not support the following constants:

  • LINEDEVSTATE_MESAGEWAITON

  • LINEDEVSTATE_MESSAGEWAITOFF

  • LINEDEVSTATE_INSERVICE

  • LINEDEVSTATE_OUTOFSERVICE

  • LINEDEVSTATE_MAINTENANCE

  • LINEDEVSTATE_TERMINALS

  • LINEDEVSTATE_ROAMMODE

  • LINEDEVSTATE_BATTERY

  • LINEDEVSTATE_SIGNAL

  • LINEDEVSTATE_LOCK

  • LINEDEVSTATE_COMPLCANCEL

Requirements

Header tapi.h
Windows Embedded CE Windows CE 3.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

500 Internal Server Error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@systemmanager.forsenergy.ru to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.