更改选项卡时,文本框上的验证工具提示会变得孤立

发布于 2024-10-06 02:01:15 字数 390 浏览 0 评论 0原文

我在 TabControl 内的 TabItem 上有一个 TextBox。使用 INotifyDataError 基于更改的验证,当 TextBox 中存在错误并且您将注意力集中在 TextBox 上时,将显示验证工具提示。如果我导航到其他选项卡,即使我位于新选项卡上,工具提示也会保留在原来的位置。本质上是创建一个孤立的工具提示。当我返回到带有验证错误的文本框的原始选项卡时,我可以通过关注文本框和切换选项卡来创建尽可能多的新的孤立验证工具提示。

我一直在尝试使用 Silverlight Spy 重新生成视觉树。 TextBox 位于一组嵌套选项卡控件上的 Grid 内的 ScrollViewer 内部。不幸的是,在我的隔离沙箱中,我目前还无法重现该问题。这意味着,切换选项卡时工具提示会消失。

还有其他人遇到过这样的事情吗?

I have a TextBox on a TabItem inside of a TabControl. Using INotifyDataError changed based validation, when there is an error in the TextBox and you focus on the TextBox a validation tooltip displays. If I navigate to a different tab, the Tooltip stays where it was even though I am on the new tab. Essentially creating an orphaned ToolTip. When I go back to the original tab with my textbox that has the validation error, I can create as many new orphaned validation tooltips by focusing on the textbox and switching tabs.

Using Silverlight Spy I've been trying to re-produce the visual tree. The TextBox is inside of a ScrollViewer inside of a Grid on a set of nested tab controls. Unfortunately, in my isolated sandbox I am as of yet unable to reproduce the issue. Meaning, the tooltip goes away when switching tabs.

Has anybody else ever encountered something like this?

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文