ContentElement.PreviewKeyUp ContentElement.PreviewKeyUp ContentElement.PreviewKeyUp ContentElement.PreviewKeyUp Event


鍵盤以此元素為焦點且放開按鍵時發生。Occurs when a key is released while the keyboard is focused on this element.

 virtual event System::Windows::Input::KeyEventHandler ^ PreviewKeyUp;
public event System.Windows.Input.KeyEventHandler PreviewKeyUp;
member this.PreviewKeyUp : System.Windows.Input.KeyEventHandler 
Public Custom Event PreviewKeyUp As KeyEventHandler 



索引鍵處理互動與其他的平台功能,例如命令和撰寫文字。Key handling interacts with other platform features such as commanding and text composition. KeyUp事件是較低層級文字的輸入的事件,可能無法如預期般部分控制項上。The KeyUp event is a lower-level text input event that might not behave as expected on certain controls. 這是文字的因為有些控制項具有複合控制項,或提供較高層級版本的類別處理輸入處理和相關事件。This is because some controls have control compositing or class handling that provides a higher-level version of text input handling and related events. 如需詳細資訊,請檢查個別控制項的文件。For details, check the documentation for individual controls.

此事件建立的別名Keyboard.PreviewKeyUp附加事件,此類別中,以便PreviewKeyUp屬於類別的成員清單時ContentElement繼承為基底的項目。This event creates an alias for the Keyboard.PreviewKeyUp attached event for this class, so that PreviewKeyUp is part of the class members list when ContentElement is inherited as a base element. 附加至事件處理常式PreviewKeyUp事件會附加至基礎Keyboard.PreviewKeyUp附加事件,並接收相同的事件資料執行個體。Event handlers that are attached to the PreviewKeyUp event are attached to the underlying Keyboard.PreviewKeyUp attached event and receive the same event data instance.

路由事件資訊Routed Event Information

識別項欄位Identifier field PreviewKeyUpEvent
路由策略Routing strategy 通道Tunneling
Delegate - 委派Delegate KeyEventHandler
  • 對應的事件反昇事件是KeyUpThe corresponding bubbling event is KeyUp.

  • 覆寫OnPreviewKeyUp實作在衍生類別中這個事件的類別處理。Override OnPreviewKeyUp to implement class handling for this event in derived classes.