2011-02-08 57 views

答えて

22

ドキュメント: http://help.infragistics.com/Help/Doc/WinForms/2011.2/CLR2.0/html/Infragistics2.Win.UltraWinGrid.v11.2~Infragistics.Win.UltraWinGrid.UltraGridBand~SortedColumns.html

あなただけのソートインジケータ(順序が重要である)、リンク上から見たコードを設定できます。第二に

UltraGridBand band = this.ultraGrid1.DisplayLayout.Bands[0]; 

// Sort the rows by Country and City fields. Notice the order in which these columns 
// are set. We want to sort by Country and then sort by City and in order to do that 
// we have to set the SortIndicator property in the right order. 
band.Columns["Country"].SortIndicator = SortIndicator.Ascending; 
band.Columns["City"].SortIndicator = SortIndicator.Ascending; 

// You can also sort (as well as group rows by) columns by using SortedColumns 
// property off the band. 
band.SortedColumns.Add("ContactName", false, false); 

さらに詳しい情報方法はここに見つけることができます: http://help.infragistics.com/Help/NetAdvantage/NET/2008.2/CLR2.0/html/Infragistics2.Win.UltraWinGrid.v8.2~Infragistics.Win.UltraWinGrid.SortedColumnsCollection~Add.html

+0

おかげで、残念ながら提供されたリンクは、もはや – Xander

+0

@Xanderええ有効ではありません、彼らは自分のサイトを切り替えたようだが、リダイレクトを追加していない。上で参照したのと同じものではありませんが、ソートに関する記事はここにあります。http://www.infragistics.com/help/topic/ED043A4B-031A-48A8-8A20-9BEA498DE71Aしかし、投稿されたソリューションはまだ有効です。 – theChrisKent

+0

ありがとう、シンプルで便利な解決策 – Rice

2

は、あなたはまた、自動的に担当者名によるグループは、これはあなたのためにそれを行うことができますしたい場合:真の

band.SortedColumns.Add("ContactName", false, true); 

お知らせの使用を最後のパラメータとして

関連する問題