Share via


IUITestEventNotify.Notify Method

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

The callback method for the event added via IUITechnologyManager.AddEventHandler.

The callback should occur on a different thread than the one used to add the event handler to make sure that the callback is not blocking adding and removing of the event handlers.

Namespace:  Microsoft.VisualStudio.TestTools.UITest.Extension
Assembly:  Microsoft.VisualStudio.TestTools.UITest.Extension (in Microsoft.VisualStudio.TestTools.UITest.Extension.dll)

Syntax

'Declaration
Sub Notify ( _
    source As IUITechnologyElement, _
    target As IUITechnologyElement, _
    eventType As UITestEventType, _
    eventArgs As Object _
)
void Notify(
    IUITechnologyElement source,
    IUITechnologyElement target,
    UITestEventType eventType,
    Object eventArgs
)
void Notify(
    IUITechnologyElement^ source, 
    IUITechnologyElement^ target, 
    UITestEventType eventType, 
    Object^ eventArgs
)
abstract Notify : 
        source:IUITechnologyElement * 
        target:IUITechnologyElement * 
        eventType:UITestEventType * 
        eventArgs:Object -> unit
function Notify(
    source : IUITechnologyElement, 
    target : IUITechnologyElement, 
    eventType : UITestEventType, 
    eventArgs : Object
)

Parameters

  • eventArgs
    Type: Object

    The EventArgs object that is provided for the event.

Remarks

In most cases, the source and target element will be the same.

However, this might not be always the case. For example, clicking a label for a check box changes the state of the check box. Here, the source is the label and the target is the check box. Similarly, when target is ComboBox, the source could be the Edit or List within it.

The source can be null, which means source and target are the same.

.NET Framework Security

See Also

Reference

IUITestEventNotify Interface

Microsoft.VisualStudio.TestTools.UITest.Extension Namespace

IUITechnologyElement

UITestEventType