控制滚动查看器的滚动距离

发布于 2024-12-31 23:34:22 字数 57 浏览 5 评论 0原文

我在滚动查看器中放置了 20 个文本块,但它最多滚动到 7 个?我还想在应用程序启动时控制滚动距离?

I'm placing 20 textblocks in scroll viewer, but it scrolling upto 7? I also want to control the scroll distance in get scrolled whenever my application starts?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

天涯离梦残月幽梦 2025-01-07 23:34:22

可能您将 ScrollViewerHeight 设置为 Auto,但它不适合屏幕。将其设置为Parent Height。我希望它能发挥作用。

Probably, you set Height of ScrollViewer to Auto and it don't fit to screen. Set it to Parent Height. I hope it will work than.

我家小可爱 2025-01-07 23:34:22

你能把你的代码贴出来吗?另请确保您已完成这两件事

1) 将其放入 grid.row 并将 grid.rwo 高度设置为 *
2)不要将滚动查看器放在堆栈面板中

Can you put up your code? Also make sure you have done these two things

1) Place it in a grid.row and set grid.rwo height to *
2) Do not place the scrollviewer in a stackpanel

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文