gpt4 book ai didi

c# - 将光标设置为网格中的指针

转载 作者:行者123 更新时间:2023-11-28 13:50:49 25 4
gpt4 key购买 nike

我有一个 Rad Grid,我只是想让光标成为悬停在每一行上的指针。我试过 Css 类,但没有用。我知道有一个简单的解决方案,我只是不知道该怎么做。以下是我尝试过的

<style type="text/css">
.UseHand
{
cursor: pointer;
}

 <telerik:RadGrid ID="RadGrid1" Skin="WB" runat="server" AutoGenerateColumns="false" DataSourceID="DSID">
<GroupingSettings CaseSensitive="false" />
<SelectedItemStyle CssClass="UseHand" />
<MasterTableView>BLAH BLAH</MasterTableView>
<ClientSettings EnableRowHoverStyle="true">
<Selecting AllowRowSelect="True" />
<ClientEvents />
</ClientSettings>
</telerik:RadGrid>

如有任何帮助,我们将不胜感激!

最佳答案

我有两个想法给你:

想法 1:在您的示例中,您将类添加到 SelectedItemStyle,我认为这是唯一选定的行,而不是所有行。相反,您可以尝试:

<ItemStyle CssClass="UseHand" />

想法 2:

您也可以尝试强制解决问题:

.UseHand
{
cursor: pointer !important;
}

并将类添加到网格本身:

 <telerik:RadGrid ID="RadGrid1" Skin="WB" CssClass="UseHand" runat="server" AutoGenerateColumns="false" DataSourceID="DSID">

这应该覆盖 RadGrid 生成的任何内置样式和内联样式。

关于c# - 将光标设置为网格中的指针,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2208490/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com