Wrox Programmer Forums
VB.NET 2002/2003 Basics For coders who are new to Visual Basic, working in .NET versions 2002 or 2003 (1.0 and 1.1).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET 2002/2003 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old January 15th, 2006, 12:47 PM
Registered User
Join Date: Jan 2006
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default DataGrid Sort

I have a problem getting the sort to work in datagrids.
In the properties window I have selected "Allow sort" to true.
I have also tried writing .Allow Sort = True into the code.

Help says Allow Sort should provide a small triangle in the header to indicate the direction of the sort. Click to toggle the direction.
The DataGrid displays as intended but I don't get the triangle and I can't sort.
What have I missed?
I know it will be something obvious (to everyone else).

I am learning (slowly)
The original problem was with a DataGrid bound to a DataGridTable.
I have now bound the DataGrid to a plain DataTable and, hooray, I now have the sort facility working OK.
However I now can't change the width of the columns.
It appears I can sort with a DataTable OR set column width with DataGridTable. I don't understand why yet!


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to sort datagrid columns sumith ASP.NET 1.0 and 1.1 Professional 3 February 19th, 2007 01:12 AM
datagrid does SORT integer data properly chayanvinayak Flash (all versions) 3 July 27th, 2006 02:59 PM
Sort Datagrid Sheikha ASP.NET 1.x and 2.0 Application Design 1 June 29th, 2005 04:46 AM
Sort and Update the DataGrid omahataz BOOK: Beginning VB.NET 2nd Edition/Beginning VB.NET 2003 8 October 9th, 2004 07:19 AM
how to sort the items in the datagrid Ramakrishna.G General .NET 1 September 24th, 2004 02:29 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.