共用方式為


ElementCompositionPreview.SetAppWindowContent(AppWindow, UIElement) 方法

定義

將 XAML UIElement 設定為 AppWindow 的內容根目錄。

public:
 static void SetAppWindowContent(AppWindow ^ appWindow, UIElement ^ xamlContent);
 static void SetAppWindowContent(AppWindow const& appWindow, UIElement const& xamlContent);
public static void SetAppWindowContent(AppWindow appWindow, UIElement xamlContent);
function setAppWindowContent(appWindow, xamlContent)
Public Shared Sub SetAppWindowContent (appWindow As AppWindow, xamlContent As UIElement)

參數

appWindow
AppWindow

要為其設定內容的 AppWindow。

xamlContent
UIElement

要設定的內容。

Windows 需求

裝置系列
Windows 10, version 1903 (已於 10.0.18362.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v8.0 引進)

適用於