Is it possible to disable the scrolling in a web browser control in Windows Phone 7.1? I have seen quite a few questions ask around it (Windows Phone 7.0, Silverlight) but an answer has yet to come up. Any ideas?
There is a blog post here explaining how to suppress the zoom and scroll functionality of the WebBrowser control. Quote from that post:
The visual tree is quite simple, composed of a few grids and borders. The significant parts are the TileHost, which is the native IE9 component, and the PanZoomContainer. The TileHost does not handle the mouse manipulation events, these are instead handled by the PanZoomContainer, where they are then translated into gestures (i.e. pinch-zoom) with the result fed back to the TileHost.
What this means is that we can intercept the manipulation events as they bubble up to the PanZoomContainer, cancelling them before they are turned into gestures.
Given the webbrowser:
To disable interaction set IsHitTextVisible
= false
<phone:WebBrowser Height="600" IsHitTestVisible="False" />
To disable scrolling only, set ScrollViewer.VerticalScrollBarVisibility
= disabled
<phone:WebBrowser Height="600" ScrollViewer.VerticalScrollBarVisibility="Disabled" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With