We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Grid Sorting, Part II

Hi - I set Grid.SortBehavior = GridSortBehavior.None, but I still get that little triangle in the column header if the underlying datatable happens to be sorted on a single column. Is there a way to turn that indicator off? Thanks!

3 Replies

AD Administrator Syncfusion Team February 24, 2003 10:42 AM

This is not default behavior. Can you post a sample showing what you are doing?


IP Ivan Pelly February 25, 2003 08:14 AM

Sure. I put a GridDataBoundGrid on a form, create a datatable, and bind as follows: SqlDataAdapter1.Fill(DataSet11) Dim gbColumn As GridBoundColumn Dim col As DataColumn For Each col In DataSet11.Tables(0).Columns gbColumn = New GridBoundColumn() gbColumn.HeaderText = col.ColumnName gbColumn.MappingName = col.ColumnName gbColumn.StyleInfo.CellType = "Static" gbColumn.ReadOnly = True GridDataBoundGrid1.GridBoundColumns.Add(gbColumn) Next GridDataBoundGrid1.SortBehavior = GridSortBehavior.None DataSet11.Tables(0).DefaultView.Sort = "SiteName" GridDataBoundGrid1.DataSource = DataSet11.Tables(0) The grid comes up with the little "up" triangle in the SiteName column header. If I comment out that line, no triangle.


AD Administrator Syncfusion Team February 25, 2003 09:17 AM

Try setting GridDataBoundGrid1.BaseStylesMap("Column Header").StyleInfo.CellType = "Header"

Loader.
Live Chat Icon For mobile
Up arrow icon