phoneGetDevCaps (Compact 2013)
3/26/2014
This function queries a specified phone device to determine its telephony capabilities.
Syntax
LONG WINAPI phoneGetDevCaps(
HPHONEAPP hPhoneApp,
DWORD dwDeviceID,
DWORD dwAPIVersion,
DWORD dwExtVersion,
LPPHONECAPS lpPhoneCaps
);
Parameters
- hPhoneApp
Handle to the application's registration with TAPI.
- dwDeviceID
Phone device to be queried.
- dwAPIVersion
Version number of the Telephony API to be used. The high-order word contains the major version number; the low-order word contains the minor version number. This number is obtained with the function phoneNegotiateAPIVersion.
- dwExtVersion
Version number of the service provider-specific extensions to be used. This number is obtained with the function phoneNegotiateExtVersion. It can be left zero if no device-specific extensions are to be used. Otherwise, the high-order word contains the major version number; the low-order word contains the minor version number.
- lpPhoneCaps
Pointer to a variably sized structure of type PHONECAPS. Upon successful completion of the request, this structure is filled with phone device capabilities information.
Return Value
Returns zero if the request succeeds or a negative error number if an error occurs. The following table shows the return values for this function.
Value |
Description |
---|---|
PHONEERR_INVALAPPHANDLE |
The handle to the application's registration with TAPI is invalid. |
PHONEERR_INVALPOINTER |
The pointer is invalid. |
PHONEERR_BADDEVICEID |
The device identifier is incorrect. |
PHONEERR_OPERATIONFAILED |
The operation failed. |
PHONEERR_INCOMPATIBLEAPIVERSION |
The API version is incompatible. |
PHONEERR_OPERATIONUNAVAIL |
The operation is unavailable. |
PHONEERR_INCOMPATIBLEEXTVERSION |
The extension version is incompatible. |
PHONEERR_NOMEM |
Not enough memory is available. |
PHONEERR_STRUCTURETOOSMALL |
The structure is too small. |
PHONEERR_RESOURCEUNAVAIL |
The resources are unavailable. |
PHONEERR_NODRIVER |
The driver was not found. |
PHONEERR_UNINITIALIZED |
A parameter was uninitialized. |
PHONEERR_NODEVICE |
The device was not found. |
Remarks
Before using phoneGetDevCaps, the application must negotiate the TAPI version number to use (see phoneNegotiateAPIVersion) and, optionally, the extension version to use (see phoneNegotiateExtVersion).
TAPI and extension version numbers are those under which TAPI, Telephony DLL, and service provider must operate. If version ranges do not overlap, the application and API or service-provider versions are incompatible and an error is returned.
Requirements
Header |
tapi.h |
Library |
TAPI32.dll |
See Also
Reference
TAPI Phone Device Functions
phoneNegotiateAPIVersion
phoneNegotiateExtVersion