AddRemoteEventListener Method
| Mercury.QTP.CustomServer Namespace > CustomServerBase Class : AddRemoteEventListener Method |
The type of the EventsListenerBase instance to be created.
Creates an EventListener instance in the AUT context.
Remarks
Call this method from a custom server running in the testing tool context.
Define a Remote EventsListenerBase class and call AddRemoteEventListener, passing the type of its Remote Event Listener class.
public class EventsListenerAssist : EventsListenerBase
{
// class implementation
}
public override void InitEventListener()
{
AddRemoteEventListener(typeof(EventsListenerAssist));
}
You can have only one Remote Event listener per Control.
Syntax
'DeclarationProtected Sub AddRemoteEventListener( _ ByVal EventListenerType As System.Type _ )
protected void AddRemoteEventListener( System.Type EventListenerType )
Parameters
- EventListenerType
- The type of the EventsListenerBase instance to be created.

