![]() |
---|
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. |
This function returns the next TAPI message that is queued for delivery to an application that is using the Event Handle notification mechanism (see phoneInitializeExfor further details).
Syntax
LONG WINAPI phoneGetMessage( HPHONEAPP hPhoneApp, LPPHONEMESSAGE lpMessage, DWORD dwTimeout ); |
Parameters
- hPhoneApp
-
Handle returned by the phoneInitializeExfunction. The application must have set the PHONEINITIALIZEEXOPTION_USEEVENT option in the dwOptionsmember of the PHONEINITIALIZEEXPARAMSstructure.
- lpMessage
-
Pointer to a PHONEMESSAGEstructure. Upon successful return from this function, the structure contains the next message that had been queued for delivery to the application.
- dwTimeout
-
Time-out interval, in milliseconds. The function returns if the interval elapses, even if no message can be returned. If dwTimeoutis zero, the function checks for a queued message and returns immediately. If dwTimeoutis INFINITE, the function's time-out interval never elapses.
Return Value
Zero indicates success. A negative error number indicates that an error occurred. The following table shows the return values for this function.
Value | Description |
---|---|
PHONEERR_INVALAPPHANDLE |
The application called the phoneShutdownfunction.while this function has been called with a nonzero time-out. |
PHONEERR_INVALPOINTER |
The pointer is invalid. |
PHONEERR_OPERATIONFAILED |
The time-out expired (or was zero) and no message could be fetched from the queue. |
PHONEERR_NOMEM |
Not enough memory is available. |
Remarks
If this function has been called with a nonzero time-out and the application calls phoneShutdownon another thread, this function returns immediately with PHONEERR_INVALAPPHANDLE.
If the time-out expires (or was zero) and no message could be fetched from the queue, the function returns with the error PHONEERR_OPERATIONFAILED.
Requirements
Header | tapi.h |
Library | coredll.lib |
Windows Embedded CE | Windows CE 3.0 and later |
Windows Mobile | Windows Mobile Version 5.0 and later |