Is it possible to disable scrolling in GridView ?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Try this inside of the GridView
<GridView
ScrollViewer.HorizontalScrollBarVisibility="Disabled">
回答2:
As an alternative you could use
<GridView ScrollViewer.HorizontalScrollMode="Disabled" />
If you're setting this property dynamically, the Scrolling will be disabled but the ScrollPosition stays (on *ScrollBarVisibilty=Disabled the ScrollPosition gets set to 0)
Dynamic Example:
ScrollViewer.SetHorizontalScrollMode(YourGridView, ScrollMode.Disabled);