NavigationCommands.Refresh 屬性

定義

取得代表 Refresh 命令的值。

public:
 static property System::Windows::Input::RoutedUICommand ^ Refresh { System::Windows::Input::RoutedUICommand ^ get(); };
public static System.Windows.Input.RoutedUICommand Refresh { get; }
static member Refresh : System.Windows.Input.RoutedUICommand
Public Shared ReadOnly Property Refresh As RoutedUICommand

屬性值

路由的UI命令。

預設值
按鍵動作 F5
UI 文字 重新整理

範例

下列範例示範如何搭配 Frame使用 Refresh 。 提供Frame實作,可藉由重載目前Frame的內容來回應Refresh命令。

<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<!-- NavigationCommands.Refresh -->
<MenuItem
  Command="NavigationCommands.Refresh"
  CommandTarget="{Binding ElementName=frame}" />
<!-- The following Frame is used to process NavigationCommands.Refresh commands -->
<Frame Name="frame" NavigationUIVisibility="Hidden" Source="Page1.xaml" />
</Window>

備註

此命令指出重新整理目前頁面的意圖。

FrameNavigationWindow 實作回應 Refresh 命令的支持,雖然您不需要使用它;在許多情況下,響應該命令的實作是應用程式寫入器的責任。

XAML Attribute Usage

<object property="NavigationCommands.Refresh"/>  

適用於

另請參閱