MenuItem.OnSubmenuOpened(RoutedEventArgs) MenuItem.OnSubmenuOpened(RoutedEventArgs) MenuItem.OnSubmenuOpened(RoutedEventArgs) MenuItem.OnSubmenuOpened(RoutedEventArgs) Method

Definición

Se le llama cuando el submenú de un MenuItem se abre.Called when the submenu of a MenuItem is opened.

protected:
 virtual void OnSubmenuOpened(System::Windows::RoutedEventArgs ^ e);
protected virtual void OnSubmenuOpened (System.Windows.RoutedEventArgs e);
abstract member OnSubmenuOpened : System.Windows.RoutedEventArgs -> unit
override this.OnSubmenuOpened : System.Windows.RoutedEventArgs -> unit
Protected Overridable Sub OnSubmenuOpened (e As RoutedEventArgs)

Parámetros

e
RoutedEventArgs RoutedEventArgs RoutedEventArgs RoutedEventArgs

Datos de evento para el evento SubmenuOpened.The event data for the SubmenuOpened event.

Ejemplos

En este ejemplo se muestra cómo usar el OnSubmenuOpened método.This example shows how to use the OnSubmenuOpened method.

private void OnSubmenuOpened(object sender, RoutedEventArgs e)
{

    if (sender == e.Source)
    {
        textBlock1.Text = "Submenu is open.";
    }
}
Private Sub OnSubmenuOpened(ByVal sender As Object, ByVal e As RoutedEventArgs)

	If sender Is e.Source Then
		textBlock1.Text = "Submenu is open."
	End If
End Sub

Se aplica a