单击列标题时禁用单元格双击事件,单击列标题时对网格进行排序.

编程入门 行业动态 更新时间:2024-10-28 15:30:27
本文介绍了单击列标题时禁用单元格双击事件,单击列标题时对网格进行排序.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我已经将datagridview列的SortMode属性设置为DataGridViewColumnSortMode.Automatic.但是我无法在dataGridView标头中看到用于排序的箭头,而且在单击标头时也无法触发cellDouble click事件.

I have set the SortMode property of a datagridview column to DataGridViewColumnSortMode.Automatic. But I am not able to see the arrow for sorting in the dataGridView header and also on clicking the header I am getting the cellDouble click event fires.

实际上是不想在单击列标题时进行单元格双击事件.我只需要在单击列标题时对网格进行排序.谁能帮我实现这一目标.

Actually I don't want the cell double click event on clicking the column header. I only need to sort the grid on clicking the column header. Can anyone please help me to achieve this.

预先感谢

Jayashree

Jayashree

推荐答案

Hello Jayashree,

谢谢您的发帖!  ;我建议您在一个MS论坛中发布您的问题,

Thank you for your post! I would suggest posting your question in one of the MS Forum,

Windows开发人员中心 > Windows窗体论坛 > Windows窗体数据控件和数据绑定 Windows Developer Center > Windows Forms Forums > Windows Forms Data Controls and Databinding

更多推荐

单击列标题时禁用单元格双击事件,单击列标题时对网格进行排序.

本文发布于:2023-11-04 06:43:23,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1557226.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:单击   标题   网格   双击   单元格

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!