RasConnectionNotificationA function (ras.h)
The RasConnectionNotification function specifies an event object that the system sets to the signaled state when a RAS connection is created or terminated.
DWORD RasConnectionNotificationA( HRASCONN , HANDLE , DWORD );
A handle to the RAS connection that receives the notifications. This can be a handle returned by the RasDial or RasEnumConnections function. If this parameter is INVALID_HANDLE_VALUE, notifications are received for all RAS connections on the local client.
Specifies the handle of an event object. Use the CreateEvent function to create an event object.
Specifies the RAS event that causes the system to signal the event object specified by the hEvent parameter. This parameter is a combination of the following values.
If the function succeeds, the return value is ERROR_SUCCESS.
If the function fails, the return value is a non-zero error code from Routing and Remote Access Error Codes or Winerror.h.
To determine when the event object is signaled, use any of the wait functions.
When the event is signaled, use other RAS functions, such as RasEnumConnections, to get more information about the RAS connection that was created or terminated.
The ras.h header defines RasConnectionNotification as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
|Minimum supported client||Windows 2000 Professional [desktop apps only]|
|Minimum supported server||Windows 2000 Server [desktop apps only]|