Page.WindowHeight 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得或設定 Window 之裝載 NavigationWindow 或 Page 的高度。
public:
property double WindowHeight { double get(); void set(double value); };
public double WindowHeight { get; set; }
member this.WindowHeight : double with get, set
Public Property WindowHeight As Double
屬性值
直接裝載 Page 之視窗的高度。
範例
下列範例示範如何從頁面設定視窗的高度。
<Page
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="SetWindowHeightPage"
WindowHeight="500"
>
</Page>
備註
WindowHeight 只有在由視窗直接裝載 時 Page ,才會套用 ,包括:
Windows Internet Explorer
Page如果 是由 Frame 裝載,則設定 WindowHeight 沒有作用,但您仍然可以取得 的值 WindowHeight 。
Page在 XAML 瀏覽器應用程式中, (XBAP) 只能用來 WindowHeight 變更 Internet Explorer Windows的高度;設定 、 MinHeight 或 MaxHeight 無法變更 Height 高度。
Internet Explorer 視窗Windows的最小高度為 150 圖元。 對於瀏覽器裝載的頁面,這表示 如果 會導致 internet Explorer 視窗的總 Windows高度小於 150 圖元,則可能不會套用 的值 WindowHeight 。