如何在Windows 8中隐藏WebView中的滚动条?

时间:2012-09-30 06:18:18

标签: xaml windows-8 scrollbar

我正试图在我的地铁应用程序中隐藏滚动条,就像我通常在windows phone app中那样:

<WebView x:Name="webView" 
    Height="395" Width="300"
    ScrollViewer.VerticalScrollBarVisibility="Hidden"
    ScrollViewer.HorizontalScrollBarVisibility="Hidden"/>

但即使我用嵌入式环绕它也不行

<ScrollViewer Name="ScrollViewerForWebView"
    Grid.Row="1"
    Grid.Column="1"
    HorizontalAlignment="Left"
    VerticalAlignment="Top" 
    VerticalScrollBarVisibility="Hidden"
    HorizontalScrollBarVisibility="Hidden">

    <WebView x:Name="webView" Height="395" Width="300" />
</ScrollViewer>

谢谢!

1 个答案:

答案 0 :(得分:0)

如果你设置

怎么办?
ScrollViewer.VerticalScrollBarVisibility="Disabled"