本文介绍了根据数值对datagridview进行排序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个未绑定的数据网格视图。它拥有为学生获得的姓名和分数。
分数为12.25,12.35等。
我想要使用像
Hi,
I have an un-bound datagrid view. It holds Names and marks obtained for students.
Marks are like 12.25, 12.35 etc.
I want to use code like
dgvSM.Sort(dgvSM.Columns(2), System.ComponentModel.ListSortDirection.Descending)
所以标记最少的那个位于顶部。但它不起作用。
datagridview正在根据文本进行排序,而不是以商业方式排序。
请帮助
我尝试了什么:
用Google搜索了很多,没有找到相关的内容
So the one with least marks comes at top. BUT it does not work.
The datagridview is being sorted based on text, not numercially.
Please help
What I have tried:
Googled alot, nothing found related
推荐答案
这篇关于根据数值对datagridview进行排序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!