怎样一个DataGridView定位到特定的行(以使所选择的行是在顶部) [英] How do I position a DataGridView to a specific row (so that the selected row is at the top)
本文介绍了怎样一个DataGridView定位到特定的行(以使所选择的行是在顶部)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有在其上一个DataGridView一个应用程序,我希望定位的行,使得一个特定行位于列表的顶端。
I have an application with a DataGridView on it and I would like to position the rows such that a specific row is at the top of the list.
我不希望有一个排序,我想以编程方式告诉DataGridView的滚动到第N行。
I don't want a sort, I want a way to programmatically tell the DataGridView "scroll to the Nth row."
任何想法?
推荐答案
如何<一个href="http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridview.firstdisplayedscrollingrowindex.aspx"><$c$c>FirstDisplayedScrollingRowIndex$c$c>?
这篇关于怎样一个DataGridView定位到特定的行(以使所选择的行是在顶部)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文