Compartir a través de


AutomationPeer.RaiseAutomationEvent Method

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Raises an automation event.

Namespace:  System.Windows.Automation.Peers
Assembly:  System.Windows (in System.Windows.dll)

Syntax

'Declaration
Public Sub RaiseAutomationEvent ( _
    eventId As AutomationEvents _
)
public void RaiseAutomationEvent(
    AutomationEvents eventId
)

Parameters

Remarks

If EventsSource is not nulla null reference (Nothing in Visual Basic), then EventsSource is reported as part of the event.

Handling an automation event including its specific automation event arguments is not enabled within the Silverlight 5 core API. Handling the event requires that the handler be part of a UI Automation client, and the infrastructure for implementing a UI Automation client is tied to the UIAutomationClient.dll assembly that is part of Microsoft Windows rather than being a part of the Silverlight core. Raising an automation event from the set that is identified by AutomationEvents does not require you to package event data; any required event data is provided by the UI Automation infrastructure when it reports the event to UI Automation clients.

Version Information

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.