Infragistics Ultralistview 鼠标悬停检索用户信息

发布于 2024-09-26 14:23:56 字数 159 浏览 13 评论 0原文

我正在使用 Infragistics Ultralistview 在列表中显示数据,其中包含 3 列和 4-5 行(根据添加的数据,最多可能有“n”行)。当我将鼠标悬停在该行上 2 秒时,我希望有关该行的其他信息应显示在类似控件的面板中。怎么做呢?

如果我方还需要任何其他信息,请告诉我。

I am using Infragistics Ultralistview to display data in List which contains 3 columns and 4-5 rows(that could be upto 'n' rows depending upon data added). When i hover over the row for 2 seconds, i want that other information about that row should be displayed in a panel like control. How to do that?

Let me know if anything else is required from my side.

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

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

发布评论

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

评论(1

[浮城] 2024-10-03 14:23:56

我已经使用控件中的 MouseEnterElement 事件并手动处理额外信息的显示,通过 Combo 完成了此类操作。

具体来说,对于我的项目,我引用了 ValueListItem 中的数据。当事件被触发时,它会为该下拉元素触发一个 UltraWinToolTip。

对于您的项目,您可能希望将额外数据归因于每个 UltraListViewItem 的 Tag 属性,并捕获 MouseEnterElement。尝试类似 (vb) 的操作:

Dim lst As UltraListView = CType(sender, UltraListView)

If e.Element.GetContext().GetType() Is GetType(UltraListViewItem) Then
    '-- Get the item in question
    Dim li As UltraListViewItem = CType(e.Element.GetContext(), UltraListViewItem)
    '-- Transpose your own data here
    Dim dr As DataRow = CType(li.Tag, DataRow)
    '-- Use a timer to delay the showing of the tip, or just set the text here
End If

然后,使用 MouseLeaveElement 进行清理,执行以下操作:

If e.Element.GetContext().GetType() Is GetType(ValueListItem) Then
    '-- Get rid of the text
End If

I've done this sort of thing with a Combo using the MouseEnterElement event from the control and processing the display of the extra information manually.

For my project specifically, I reference the data from a ValueListItem. When the event is triggered, it fires up an UltraWinToolTip for that dropdown element.

For your project, you might want to attribute your extra data to the Tag property of each UltraListViewItem, and capture the MouseEnterElement. Try something like (vb):

Dim lst As UltraListView = CType(sender, UltraListView)

If e.Element.GetContext().GetType() Is GetType(UltraListViewItem) Then
    '-- Get the item in question
    Dim li As UltraListViewItem = CType(e.Element.GetContext(), UltraListViewItem)
    '-- Transpose your own data here
    Dim dr As DataRow = CType(li.Tag, DataRow)
    '-- Use a timer to delay the showing of the tip, or just set the text here
End If

Afterwards, clean up by using MouseLeaveElement, doing something along the lines of:

If e.Element.GetContext().GetType() Is GetType(ValueListItem) Then
    '-- Get rid of the text
End If
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文